matrix-creator-hal
matrix-creator-hal copied to clipboard
Can’t send SPI message - Resin.io
I am using a Raspberry Pi 3 with a Matrix Creator board and resin.io. Resin uses dockerfiles to push deployments to multiple connected devices, and using the Matrix documentation in the matrix-creator-hal readme I installed the necessary dependencies for the board through the dockerfile and tried to run the “mic_energy_direct” demo.
However, I get the following output when running any of the matrix examples that involve the microphones:
“can’t send spi message”
This does not occur with any LED or sensor examples, just ones involving the microphone array. I have no problem running the examples in a regular (non-Resin) installation.
Resin enables spi by default, but I also used modprobe spi-bcm2835 in the RUN command to no avail.
Has anyone had success using Matrix+Resin.io? Any help would be greatly appreciated.
Here is my dockerfile, for reference:
FROM resin/%%RESIN_MACHINE_NAME%%-python
RUN curl https://apt.matrix.one/doc/apt-key.gpg | apt-key add - &&
echo "" >/boot/cmdline.txt &&
apt-get update && apt-get upgrade &&
apt-get install --no-install-recommends apt-utils && \
apt-get -y install python3-pip python-pip &&
apt-get install lsb-release apt-transport-https &&
echo "deb https://apt.matrix.one/raspbian $(lsb_release -sc) main" | tee /etc/apt/sources.list.d/matrixlabs.list &&
apt-get update && apt-get upgrade
RUN curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py &&
python3 get-pip.py --force-reinstall
RUN apt-get install cmake g++ git libfftw3-dev wiringpi matrixio-creator-init matrixio-malos libgflags-dev &&
apt-get install sox alsa-utils &&
apt-get install python-cryptography &&
apt-get install python3-dev &&
apt install libmatrixio-creator-hal libmatrixio-creator-hal-dev libsdl1.2-dev &&
apt-get clean && rm -rf /var/lib/apt/lists/*
WORKDIR /usr/src/app
COPY ./requirements.txt /requirements.txt
RUN pip3 install -r /requirements.txt
COPY . ./
ENV INITSYSTEM on
CMD python3 src/loop.py
I am also looking to do this