While trying to set up my Coral Dev Board Micro, I keep receiving error messages when running setup.sh. The program always fails to build the wheel for hidapi.
(.venv) henrydenham@Henrys-MacBook-Air-3 ~ % cd coralmicro && bash setup.sh
==> Downloading https://formulae.brew.sh/api/formula.jws.json
==> Downloading https://formulae.brew.sh/api/cask.jws.json
######################################################################################################################################################################################################### 100.0%
Warning: Treating cmake as a formula. For the cask, use homebrew/cask/cmake or specify the `--cask` flag.
Warning: cmake 3.30.3 is already installed and up-to-date.
To reinstall 3.30.3, run:
brew reinstall cmake
Warning: libusb 1.0.27 is already installed and up-to-date.
To reinstall 1.0.27, run:
brew reinstall libusb
Warning: lsusb 1.0 is already installed and up-to-date.
To reinstall 1.0, run:
brew reinstall lsusb
Requirement already satisfied: pip in /Users/henrydenham/.venv/lib/python3.12/site-packages (24.2)
Collecting hexformat==0.2 (from -r /Users/henrydenham/coralmicro/scripts/requirements.txt (line 1))
Using cached hexformat-0.2-py3-none-any.whl
Collecting hidapi==0.10.1 (from -r /Users/henrydenham/coralmicro/scripts/requirements.txt (line 2))
Using cached hidapi-0.10.1.tar.gz (60 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Installing backend dependencies ... done
Preparing metadata (pyproject.toml) ... done
Collecting progress==1.5 (from -r /Users/henrydenham/coralmicro/scripts/requirements.txt (line 3))
Using cached progress-1.5-py3-none-any.whl
Collecting pyserial==3.5 (from -r /Users/henrydenham/coralmicro/scripts/requirements.txt (line 4))
Using cached pyserial-3.5-py2.py3-none-any.whl.metadata (1.6 kB)
Collecting pyusb==1.2.0 (from -r /Users/henrydenham/coralmicro/scripts/requirements.txt (line 5))
Using cached pyusb-1.2.0-py3-none-any.whl.metadata (2.2 kB)
Requirement already satisfied: setuptools>=19.0 in /Users/henrydenham/.venv/lib/python3.12/site-packages (from hidapi==0.10.1->-r /Users/henrydenham/coralmicro/scripts/requirements.txt (line 2)) (74.1.2)
Using cached pyserial-3.5-py2.py3-none-any.whl (90 kB)
Using cached pyusb-1.2.0-py3-none-any.whl (58 kB)
Building wheels for collected packages: hidapi
Building wheel for hidapi (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for hidapi (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [9 lines of output]
running bdist_wheel
running build
running build_ext
/private/var/folders/ls/yqdydknj10z9gwcg3mhjk9740000gn/T/pip-build-env-cbg4441a/normal/lib/python3.12/site-packages/Cython/Compiler/Main.py:381: FutureWarning: Cython directive 'language_level' not set, using '3str' for now (Py3). This has changed from earlier releases! File: /private/var/folders/ls/yqdydknj10z9gwcg3mhjk9740000gn/T/pip-install-tmixese0/hidapi_9176b98d857e44b8bf85bd6d764b39d4/hid.pyx
tree = Parsing.p_module(s, pxd, full_module_name)
Compiling hid.pyx because it changed.
[1/1] Cythonizing hid.pyx
building 'hid' extension
error: unknown file type '.pxd' (from 'chid.pxd')
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for hidapi
Failed to build hidapi
ERROR: ERROR: Failed to build installable wheels for some pyproject.toml based projects (hidapi)
I have tried backtracking versions of hidapi and python as well as following the solution of a similar question. However, their solution did not work for me.