2. Repository Structure
All directory names are abbreviated (e.g., conf
for configuration
) to
ensure a compact repository structure and avoid long command lines during build
steps.
2.1. Repository root .
The repository is generally structured as shown below:
Directory Name |
Long Name |
Content Description |
---|---|---|
|
Repository root |
The repository root contains the license information, installation instructions, a link to the changelog, the main build script |
|
Command line interface |
Program to interact with the repository |
|
Configuration |
Contains all high level configurations |
|
Documentation |
Documentation source files |
|
Hardware |
Hardware schematics and layouts |
|
Source |
Parent directory for all source files for the BMS embedded software |
|
Tests |
Tests for embedded sources, the tool chain, the conda environment and scripts |
|
Tools |
Tools needed to build foxBMS 2 binaries and additional tools to work with foxBMS 2 |
2.2. Configuration directory conf
The conf
directory is structured as shown below:
Directory Name |
Long Name |
Content Description |
---|---|---|
|
Battery Management System |
Configuration of the BMS (e.g., which AFE is used) |
|
C compiler |
Compiler configuration (e.g., compiler flags) |
|
Environment |
Environment specifications configuration files (e.g., Conda package dependencies) |
|
HALCoGen |
HALCoGen configuration files for the Hardware Abstraction Layer |
|
Templates |
Template files for source files |
|
Unit tests |
Unit test configuration files |
2.3. Documentation directory docs
This directory contains the sources of the general documentation generate by Sphinx. It further contains the configuration for the API documentation generated by Doxygen.
2.4. Hardware directory hardware
This directory contains information about the hardware schematics and layouts.
2.5. Source directory src
The src
directory is structured as shown below:
Directory Name |
Long Name |
Content Description |
---|---|---|
|
Application |
Sources files for the BMS application |
|
Hardware |
Source files of the Hardware Abstraction Layer |
|
Optional |
Optional source files (e.g., specific cell parameters) |
|
Operating System |
Source files of the real time operating system |
2.6. Tests directory tests
The tests
directory is structured as shown below:
Directory Name |
Long Name |
Content Description |
---|---|---|
|
Axivion |
Configuration files to describe the software architecture of foxBMS 2. Additional static program analysis configurations are stored here (e.g., MISRA-C) |
|
CAN |
Heuristic tests for the correct implementation of DBC file in the code |
|
Code Composer Studio |
Compiler setup for different CCS versions to compile foxBMS with |
|
Command line interface |
Tests for the CLI tool, to interact with the repository |
|
C Standard |
Test setup for foxBMS’s C standard detection |
|
CAN Database |
Check the validity of the DBC/SYM files |
|
Hardware-in-the-Loop |
Tests and setup of the Hardware-in-the-Loop test (not published) |
|
OS information |
Information to search the sources for OS relevant includes, names etc. |
|
Regex names |
Scripts to verify the regular expressions that are used in Axivion setup |
|
Embedded code unit tests |
Unit test code for the embedded code |
|
Variants |
foxBMS build configurations (for testing in e.g., CI) |
2.7. Tools directory tools
The tools
directory is structured as shown below:
Directory Name |
Long Name |
Content Description |
---|---|---|
|
Cyclic redundancy check |
Helper script and information for working with CRC-functions |
|
CAN Database |
CAN message and signal description |
|
Debugger |
Debugger setups and usage |
|
Deploy |
Scripts for deploying the generated documentation internally |
|
Editor/IDEs |
Setups for editors and Integrated Development Environments |
|
Precharge |
Script to help dimensioning the precharge resistor |
|
Utils |
Unspecific helper tools and scripts |
|
Vendor |
Vendored, unchanged files |
|
Waf tools |
Waf tools that are not part of vendored Waf |
|
Waf |
Waf binary |