Motorcortex-python installation on Windows

Install Python 3.10 or later

Download Python 3 from the Python downloads page for Windows. Choose the appropriate installer for your system, and make sure it is Python 3.10 or later — motorcortex-python does not import on older versions.

  1. Launch the installer and choose Customize installation.

    The Python installer with Customize installation selected
  2. All options are selected by default (documentation and test suite are optional). Click Next.

    The Python installer optional features step
  3. Under the Advanced Options select Add Python to environment variables.

    The Python installer advanced options step
  4. Click Install.

Python 3 is now installed.

Installing Motorcortex-python

Motorcortex-python is the core library required for any Motorcortex client application. It provides convenient ways to communicate with Motorcortex-based applications.

Motorcortex-python is installed with the pip tool. You have to be connected to the internet to install packages using pip.

  1. Open a Command Prompt by pressing the Windows key and typing cmd.

  2. In the Command Prompt window type:

    python -m pip install motorcortex-python
    

The motorcortex-python package is now installed for the current user.

Alternative installation instructions

Alternatively you can use the Miniconda package and environment management system.

Install Miniconda Python 3

Download Miniconda Python 3 from the Miniconda documentation. Choose the appropriate installer for your system.

  1. Launch the installer.

  2. Click Next.

    The Miniconda installer welcome step
  3. Click I Agree.

    The Miniconda installer license agreement step
  4. Select who the installation is designated for and click Next.

    The Miniconda installer installation type step
  5. Choose your destination folder and click Next.

    The Miniconda installer destination folder step
  6. Select Register Anaconda as my default Python.

    The Miniconda installer advanced options step
  7. Click Install to start the installation.

  8. Click Finish to close the installer.

The Conda cheat sheet is a convenient reference when using Miniconda.

Create an environment

Open an Anaconda Prompt by pressing the Windows key, typing anaconda, and selecting it from the results.

  1. In the Anaconda Prompt window, create the mcx-env environment:

    conda create -n mcx-env python=3.10
    
    The Anaconda Prompt creating the mcx-env environment
  2. To remove an environment again, use:

    conda env remove -n mcx-env
    
Activate the environment

Activate the environment:

conda activate mcx-env