How to Build Heliflight 3D - heliflight3d/heliflight GitHub Wiki

How to Build/Compile Heliflight 3D

These are my “Quick and Dirty” build environment instructions for Windows 10:

Install Windows Subsystem for Linux

Install Ubuntu 18.04 LTS from the Microsoft Store

  • Visit here for instructions on how to enable it: https://aka.ms/wslinstall
  • Must right-click on Powershell and Run as Admin
  • Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux

Run these commands inside Linux:

  • sudo apt-get update
  • sudo apt install python curl -y
  • sudo apt install build-essential
  • mkdir src
  • cd src

Ideally from here you would fork the Heliflight repo to your own account on Github and setup "git" to pull the code from your repo. This requires some configuration in Linux that you will need to do some web searching to get working. If you don't want to go through all the Github SSH key nonsense and aren't going to push commits to your own branch/contribute to Heliflight, then you can just run the following command:

You probably want to switch to whatever the branch is that has the newest development going on. Currently that is the "master" branch:

  • git checkout master

Setup the ARM Software Development Kit:

  • cd heliflight
  • make arm_sdk_install

To create a build for the STM32F722 Unified Target:

  • make STM32F7X2

Other supported targets are STM32F745, STM32F405 and STM32F411.

Now you need to get at the .hex firmware file that has been compiled in the "\home<username>\src\heliflight\obj" directory. Windows has a way to access the Linux subsystem files from Windows Explorer using a fake network share named: \wsl$\ This requires a fairly new build of Windows 10 to work. There are other ways to access files in WSL also. You will need to do something like this to get at the firmware files you have built in order to flash them to the flight controller. See more info on accessing files in the WSL subsystem here: https://devblogs.microsoft.com/commandline/whats-new-for-wsl-in-windows-10-version-1903/

More info (some may be out-dated):

⚠️ **GitHub.com Fallback** ⚠️