Development Environment Setup
Download the Microsoft Visual Studio 2022 Community installer.
Launch the installer. On the “Workloads” tab, select the “Desktop development for C++” option. On the “Individual Components” tab, select “Windows 10 SDK (10.0.19041.0)” (this should be preselected on Windows 10 systems but must be manually included on Windows 11 systems). Proceed with the installation as configured.
Create a
Projectsdirectory in your%USERPROFILE%directory, e.g.C:\Users\<your-user-name>for the Beanable SDK repository.Note: The Beanable SDK repository can be downloaded to any directory. These instructions assume the Beanable SDK is downloaded to the
%USERPROFILE%directory.Download the Beanable repository, or use the
gitcommand line tool as follows:cd %USERPROFILE%\Projects git clone https://github.com/Beanable-OpenSource/beanable
Open the “Environment Variables” dialog of the Control Panel app by following these instructions. From that dialog:
Create a User Variable called
BEANABLEand set it to point at your local Beanable SDK repository directory. Update the path as necessary for you system by navigating to the Beanable SDK folder using the “Browse Directory…” button.Variable Name:
BEANABLEVariable Value:
%USERPROFILE%\Projects\beanable
Edit the User Variable
Pathto include the Beanable SDK tools directory. Update the path as necessary for your system by navigating to the correct folder using the “Browse…” button.
Variable Name:
PathVariable Value (add to the existing list):
%USERPROFILE%\Projects\beanable\build\bin\win\release
Note: The
%USERPROFILE%\Projects\beanable\build\bin\win\releasedirectory will be created in the next step. It is safe to set the environment variable now or to come back after Step 6 to add it to thePath.Note: Make sure you open a new Command Prompt after setting the environment variables. The new environment settings will not take effect in existing Command Prompt instances.
Launch the “x86 Native Tools Command Prompt for VS 2022” command line console. Build the Beanable command line tools, simulator, and debugger from the command line:
cd %BEANABLE%\build\makefiles\win build
Note: There is an alternative build batch file called
parallel_build.batthat can be used on multi-core systems to significantly speed up the Beanable SDK build. It is, however, more difficult to see diagnostic error messages when using this batch file. Ifbuild.batworks correctly on your system, consider usingparallel_build.batfor future Beanable SDK builds.Launch the
xsbugdebugger from the command line:xsbug
Verify the host environment setup by building the starter
helloworldapplication for the desktop simulator target:cd %BEANABLE%\examples\helloworld mcconfig -d -m -p win
IMPORTANT: You can now build and run applications for the desktop simulator. To build and run applications on a development board or MCU, you need to install additional SDKs, drivers, and development tools for your target platform. See the What’s Next (Building and Running Apps on Development Boards and MCUs) section of this document for more details and links to instructions.