Install the sphinx
tool and run the following command from the root directory.
# Install the documentation generation tools
pip install sphinx sphinx_rtd_theme
pip install -I micropython-stm32-stubs
# Generate the codes module docstring information
sphinx-apidoc -o docs src
# Generate the documentation
sphinx-build -M html src _build
# This is also handled by the makefiles at the project root
make html