This document serves as a short summary on how to setup the host machine for development of foxBMS 2.
For more detailed installation instructions (that include more automation and less user interaction during the installation) for the host machine see docs/getting-started/software-installation.rst.
NOTE 1:
Read the documentation carefully and follow every point exactly as described.
Otherwise, the configuration workload in later points of the setup or the development will be significantly higher.NOTE 2:
These are the installation instructions for the host machine.
These are NOT the instructions for installing (i.e., flashing) the created binary on the target.
Flashing the binary requires a hardware debugger/flashing tool.
-
Install git.
-
Clone the repository into a path, that does NOT contain whitespace
git clone https://github.com/foxBMS/foxbms-2
-
Install Code Composer Studio (CCS) version 12.0.0 (chose
Windows single file (offline) installer for Code Composer Studio IDE (all features, devices)
).
When running the installer:- Do NOT change the default installation directory chosen by the
installer
(e.g.,
C:\ti\ccs1200
for CCS 12.0.0) and let the installer proceed with the installation. - Select the Hercules™ Safety MCUs option during the installation.
- Do NOT change the default installation directory chosen by the
installer
(e.g.,
-
Install HALCoGen version 04.07.01.
When running the installer:- Do NOT change the default installation directory chosen by the
installer
(e.g.,
C:\ti\Hercules\HALCoGen\v04.07.01
for HALCoGen 04.07.01) and let the installer proceed with the installation.
- Do NOT change the default installation directory chosen by the
installer
(e.g.,
-
Install Python.
If you have already installed Python from https://www.python.org this step can be skipped.NOTE 3:
The minimum required Python version is 3.10.
-
Open a terminal and run
py --version
, this should print something likePython 3.12.4
or similar to the terminal:py --version Python 3.12.4
-
Create a virtual environment 2025-01-pale-fox by running in
cmd.exe
orPowerShell
.-
cmd.exe
:py -m venv %USERPROFILE%\foxbms-envs\2025-01-pale-fox
-
PowerShell
:py -m venv $env:USERPROFILE\foxbms-envs\2025-01-pale-fox
-
-
Activate the virtual environment by running in
cmd.exe
or ``PowerShell`.-
cmd.exe
:%USERPROFILE%\foxbms-envs\2025-01-pale-fox\Scripts\activate.bat
-
PowerShell
:&"$env:USERPROFILE\foxbms-envs\2025-01-pale-fox\Scripts\activate.ps1"
-
-
Install the required packages by running:
cd path\to\foxbms-2 # cd into the root of the repository python -m pip install -r requirements.txt --no-deps
-
Install Ruby
-
Download the installer version for Ruby 3.1.3-x64 without Devkit.
-
Use
C:\Ruby\Ruby3.1.3-x64
as installation directory -
Do NOT add Ruby to
PATH
. -
Install the required packages, i.e., Gems by running:
cd path\to\foxbms-2 # cd into the root of the repository cd tools\vendor\ceedling C:\Ruby\Ruby3.1.3-x64\bin\bundle install # install the Ruby Gems
-
-
Install GCC
NOTE: Installing MinGW64 requires 7-Zip to be installed. 7-Zip can be download from https://7-zip.org.
- Download MinGW-W64 version x86_64-posix-seh from sourceforge.net (use exactly this 7z-archive).
- Extract the archive.
- Copy the extracted mingw64 directory to
C:\mingw64\x86_64-8.1.0-release-posix-seh-rt_v6-rev0
. - Verify that
gcc.exe
is available atC:\MinGW64\x86_64-8.1.0-release-posix-seh-rt_v6-rev0\mingw64\bin\gcc.exe
.
-
Install Doxygen
- Download Doxygen version 1.11.0 from GitHub (use this zip-archive).
- Extract the archive.
- Copy the extracted archive to
C:\Users\<username>\doxygen\1.11.0
. - Verify that
doxygen.exe
is available atC:\Users\<username>\doxygen\1.11.0\doxygen.exe
.
-
Install Graphviz
- Download GraphViz version 11.0.0 from https://graphviz.org/download (use this zip-archive).
- Extract the archive.
- Copy the extracted archive to
C:\Users\<username>\graphviz\11.0.0
. - Verify that
dot.exe
is available atC:\Users\<username>\graphviz\11.0.0\bin\dot.exe
.
-
Check that all required software is installed by running in
cmd.exe
orPowerShell
.-
cmd.exe
:fox.bat install --check
-
PowerShell
:.\fox.ps1 install --check
-
-
(Optional): Install VS Code.
- Download VS Code from the project website at Visual Studio Code.
- Install code: |foxbms| recommends installing |code| with the
User Installer
, which does not require elevated rights. - Optional: Let the installer add code to the
PATH
variable.
All required software is now installed.
Sometimes it might be required to update the build environment. It that is the case, it is then mentioned in the CHANGELOG.md.
To update the build environment the following steps must be done:
NOTE: The placeholder
<name-of-the-new-env>
must be replaced with the actual name of the new build environment, which is then documented in the CHANGELOG.md.
-
Create a virtual environment
<name-of-the-new-env>
by running incmd.exe
orPowerShell
.-
cmd.exe
:py -m venv %USERPROFILE%\foxbms-envs\<name-of-the-new-env>
-
PowerShell
:py -m venv $env:USERPROFILE\foxbms-envs\<name-of-the-new-env>
-
-
Activate the virtual environment by running in
cmd.exe
or ``PowerShell`.-
cmd.exe
:%USERPROFILE%\foxbms-envs\<name-of-the-new-env>\Scripts\activate.bat
-
PowerShell
:&"$env:USERPROFILE\foxbms-envs\<name-of-the-new-env>\Scripts\activate.ps1"
-
-
Install the required packages by running:
cd path\to\foxbms-2 # cd into the root of the repository python -m pip install -r requirements.txt --no-deps