Skip to main content
Brain Simulator III

Runs on MAC! Instructions Here

By April 12, 2024No Comments

Member Yida Xin has created instructions for running BrainSim on a MAC

Steps to set up Brain Simulator III in macOS (Sonoma (Version 14.4.1))

Step 1: Install Windows 11 (64-bit) Using VirtualBox

Follow this video: https://youtu.be/vxxEGiMR4sw?si=cCfi-Mv3tZrt3C_B . One caveat is that the latest VirtualBox version 7.0.14 has a different interface than the VirtualBox version 6.1.30 in the video. I just poked around VirtualBox v7.0.14 because I did not feel like the differences were that significant.  But if you would like to do everything verbatim from the video, go to https://www.virtualbox.org/wiki/Download_Old_Builds_6_1  navigate down to “VirtualBox6.1.30 (Released November 22 2021)”, click on “macOS / Intel hosts” to download.

Step 2: Install Visual Studio in Windows 11

Inside the Windows 11 you had just set up, go to https://visualstudio.microsoft.com/downloads/  and download any version of Visual Studio 2022 installer, though the free Community version should work just fine.  A caveat is that Visual Studio ≠ Visual Studio Code (VS Code).  Make sure to it is indeed **Visual Studio** that you are downloading, thought feel free to mess with VS Code later if you want!

After the download is complete, run the installer.  You can install Visual Studio wherever you want.  When you need it, just use the search mechanism in Windows 11 to search for it.

Step 3: Download the BrainSimIII

Start Visual Studio 2022. Near the upper right of the opening screen, click “Clone a repository”. Enter this URL in the upper textbox: https://github.com/FutureAIGuru/BrainSimIII.git  The lower textbox can be the directory of your choice and the default is fine. Click “Clone”. You may need to enter GitHub credentials.  Visual studio will clone the repository and open it.

To view source code, expand the tree in the upper right-hand pane labelled “Solution Explorer”. You’ll find most of the interesting code in the “Modules” folder. NOTE that this is the source tree of the project which may be somewhat different from the source code on disk (the disk can include files not included in the project).

To compile and start the Brain Simulator, press the green “BrainSimulator” button in the top screen. You will be running in the debugger and can set breakpoints with F9, single-step with F10, edit the code while it is running, and more other features than you can learn.

The GitHub branch you are using is “main”. DO NOT MAKE CODE CHANGES HERE. Click on “main” then “Remote Branches” and select a different branch or create a new one before making changes.

Step 3a ALTERNATE: Install Git in Windows 11 && Git-clone BrainSimIII Repo

In the previous step 3, we took advantage of Visual Studio’s limited implementation of the GitHub interface. It is good for most things but if you are already familiar with the GitHub app, here are directions of how to use it.

Go to https://git-scm.com/download/win  You can simply click “Click here to download” to get the 32-bit version of Git for Windows.  It works for me, so it will probably work for you, too.  Or you can try any of the other installers right beneath it.

You can choose any directory or path you want to download this, but the default “C:\Program Files\Git” will do. Once you have Git downloaded and installer, go to that Git folder, and open up the “git-bash” executable.  A Terminal-like console will pop up, and then you can use good old Unix-like command lines in this Git Bash!  Do  > cd ~to ensure that you are at the “home” directory, “/c/users/<name>” which corresponds to the actual “C:\Users\<name>” directory. Then, back inside Git Bash, go to the directory where you want BrainSimIII git-cloned  > cd /path/to/<desired_dir> and you can git-clone BrainSimIII from source  > git clone https://github.com/FutureAIGuru/BrainSimIII.git

Step 3b ALTERNATE: Import BrainSimulator.sln into Visual Studio

Fire up Visual Studio, and you will see a startup window that asks you what you want to open.  Go to “Get started” on the right and click on “Open a project or solution”.  A window will pop up. Go to the folder where you git-cloned BrainSimIII, click open the BrainSimIII folder, you will find a “BrainSimulator.sln” file. Select that file, and then click “Open”.

Now, you wait patiently for Visual Studio to take care of the rest for you.  After Visual Studio is done, go to the top panel inside Visual Studio interface, you will see a buttonS with a filled green arrow with “BrainSimulator” written to its right. Click that button, and in a few seconds, you will see the Brain Simulator III interface fire up. At this point, it is running in the Visual Studio Debugger.

And voila, you did it!

p.s.

This instruction may be specific to various factors, e.g. the macOS version, the VirtualBox version, the way you set up the Windows 11 disk image in Step 1, etc etc etc…  If you have any trouble things configured, feel free to email Yida Xin: <yxin@bu.edu>.