QUICK START#

Requirements#

  • XTC Tools 15.3.0

  • CMake 3.20 or higher

  • Python 3.10 or higher

It is recommended to use Ninja or xmake as the make system under Windows. Ninja has been observed to be faster than xmake, however xmake comes natively with XTC tools. This firmware has been tested with Ninja version v1.11.1.

To install Ninja, follow these steps:

  • Download ninja.exe from the Ninja release page and save to a suitable location such as C:\Program Files\ninja.

  • Ensure Ninja is on the command line path. It may be added to the system path using the following command: set PATH=%PATH%;C:\Program Files\ninja. This will work for the lifetime of the current command prompt.

  • The Ninja path may be permanently added to the system path using setx (use with caution) or via the Windows GUI: Control panel -> Advanced system settings -> Environment variables -> System variables -> Path

The correct installation of Ninja can be tested by typing ninja under an XTC Tools Command Prompt. The following error will be seen verifying that Ninja is correctly on the path but run from a directory not containing any document source files:

ninja: error: loading 'build.ninja': The system cannot find the file specified.

Building#

The following instructions show how to build the Voice Framework and run one of the example applications. This procedure is currently supported on MacOS, Linux and Windows.

  1. Enter the clone of the Voice Framework and initialise submodules

    cd fwk_voice
    git submodule update --init --recursive
    
  2. Create a python environment and install xmos-ai-tools

    pip install -r requirements.txt
    
  3. Create a build directory

    mkdir build
    cd build
    
  4. Run cmake to setup the build environment for the XMOS toolchain

    • On Linux and Mac

      cmake --toolchain ../xmos_cmake_toolchain/xs3a.cmake ..
      
    • On Windows

      # make sure you have the patch command available
      cmake -G "Ninja" --toolchain  ../xmos_cmake_toolchain/xs3a.cmake ..
      
  5. Running make will then build the Voice Framework libraries and example applications

    • On Linux and Mac

      make fwk_voice_example_bare_metal_aec_1_thread
      
    • On Windows

      ninja fwk_voice_example_bare_metal_aec_1_thread
      
  6. Install dependencies

    • On Linux and Mac

      pip install -e build/fwk_voice_deps/xscope_fileio/
      
    • On Windows

      pip install -e fwk_voice_deps/xscope_fileio
      cd fwk_voice_deps/xscope_fileio/host
      cmake -G "Ninja" .
      ninja
      cd ../../../
      
  1. Run the single-threaded AEC example

    cd ../examples/bare-metal/aec_1_thread
    python ../shared_src/python/run_xcoreai.py ../../../build/examples/bare-metal/aec_1_thread/bin/fwk_voice_example_bare_metal_aec_1_thread.xe --input ../shared_src/test_streams/aec_example_input.wav
    

    See Example Applications section in the User Guide for full details about the examples.