I can't figure out how to flash my MATRIX Voice

Happy holidays!

I have tried for a bunch of hours and I can’t figure out how to get my MATRIX Voice working to use as an ESP32 Rhasspy satellite. It seems the first thing I need to do is plug the device into a Pi so that it can be flashed - after that it looks like OTA updates will take care of it.

I do see the device in the output of aplay -l:

card 1: MATRIXIOSOUND [MATRIXIO-SOUND], device 1: matrixio.pcm-out.0 snd-soc-dummy-dai-1 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0

But I have been unable to access the device (which is plugged into the Pi’s GPIO pins) in order to flash it.

When I try to deploy, this is what seems to eventually fail:

pi@raspberrypi:~/esp32-platformio $ esptool.py --chip esp32 --port /dev/ttyMATRIX0 --baud 115200 --before default_reset --after hard_reset erase_flash
esptool.py v3.3-dev
Serial port /dev/ttyMATRIX0
Connecting...
Failed to get PID of a device on /dev/ttyMATRIX0, using standard reset sequence.
...................................

A fatal error occurred: Failed to connect to ESP32: No serial data received.
For troubleshooting steps visit: https://github.com/espressif/esptool#troubleshooting

Does anyone know what I am doing wrong?

Yes, how did you do that?
Did you follow step 1 and 2 from this guide?
https://matrix-io.github.io/matrix-documentation/matrix-voice/esp32/

Where does this tty come from? Try the command which is in the guides: /dev/ttyS0

It seems to me you did not follow the guides or got lost somewhere.
Can you backtrace your steps on which guides you have used?

This seemed like the most logical tty in the list.

I don’t have a /dev/ttyS0:

pi@raspberrypi:~/matrixio_hal_esp32/examples/mic_energy $ ls /dev/ttyS0
ls: cannot access '/dev/ttyS0': No such file or directory

The first step I wasn’t able to do was the first step :slight_smile:

pi@raspberrypi:~/matrixio_hal_esp32/examples/mic_energy $ sudo apt-get update
Hit:2 http://raspbian.raspberrypi.org/raspbian bullseye InRelease
Hit:3 http://archive.raspberrypi.org/debian bullseye InRelease
Ign:1 https://s3.amazonaws.com/apt.matrix.one/raspbian bullseye InRelease
Err:4 https://s3.amazonaws.com/apt.matrix.one/raspbian bullseye Release
  404  Not Found [IP: 54.231.136.40 443]
Reading package lists... Done
E: The repository 'https://apt.matrix.one/raspbian bullseye Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

This is after running the steps to add the repo. Do you have any ideas what might be wrong?

I tried to work around this by cloning the repo but it seems that didn’t handle all the dependencies.

Thanks again for your assistance.

Did you attach the Matrix Voice via the headers?
Reading the error message, it seems the package is not supported in the new RaspbianOS
I suggest staring again with a fresh install of an older version like:

Maybe try this?

I was able to get it to work (easily) after using the “legacy” Raspbian release - Buster seems to not be supported yet even if you have a supported kernel.

1 Like