Matrix Voice - MATRIX device has not been detected (No JTAG Chain found)

Hi Matrix-Team,

I have problems to get my Matrix Voice work :frowning_face:. I found some threads but there is no solution at the end ([1] Matrix Creator seems to be bricked (****Could not program FPGA) [2] Matrix device has not been detected

I am trying to reinstall my Matrix Voice, but still have no access to any parts on it.

I try the steps on the troubleshooting page, but it don’t fix the problem.
I expect that it is a problem with the GPIOs (see below)?

For the 1st time the Matix Voice show the yellow startup LED sequence with one LED OFF but after changing something (new installation) they are all OFF?!

Technical Parameters:

  • RaspberryPi 4B 2GB
  • install the latest Raspian buster (I start with full and now lite)
  • power supply 5V 3.0A
  • 1st 32GB and now 16GB SD Card

sudo cat /sys/kernel/debug/gpio

result

gpiochip0: GPIOs 0-53, parent: platform/fe200000.gpio, pinctrl-bcm2835:
 gpio-18  (                    |sysfs               ) out hi
 gpio-26  (                    |sysfs               ) out lo
 gpio-42  (                    |led0                ) out lo

gpiochip2: GPIOs 100-101, brcmvirt-gpio, can sleep:

gpiochip3: GPIOs 488-503, parent: spi/spi0.0, matrixio-gpio, can sleep:

gpiochip1: GPIOs 504-511, parent: platform/soc:firmware:gpio, raspberrypi-exp-gpio, can sleep:
 gpio-504 (BT_ON               )
 gpio-505 (WL_ON               )
 gpio-506 (PWR_LED_OFF         |led1                ) out lo
 gpio-507 (GLOBAL_RESET        )
 gpio-508 (VDD_SD_IO_SEL       |vdd-sd-io           ) out hi
 gpio-509 (CAM_GPIO            )
 gpio-510 (                    )
 gpio-511 (                    )

cd /usr/share/matrixlabs/matrixio-devices
sudo xc3sprog -c sysfsgpio_voice blob/bscan_spi_s6lx9_ftg256.bit

result

XC3SPROG (c) 2004-2011 xc3sprog project $Rev: 774 $ OS: Linux
Free software: If you contribute nothing, expect nothing!
Feedback on success/failure/enhancement requests:
        http://sourceforge.net/mail/?group_id=170565
Check Sourceforge for updates:
        http://sourceforge.net/projects/xc3sprog/develop

No JTAG Chain found

sudo xc3sprog -j -c sysfsgpio_voice

result

XC3SPROG (c) 2004-2011 xc3sprog project $Rev: 774 $ OS: Linux
Free software: If you contribute nothing, expect nothing!
Feedback on success/failure/enhancement requests:
        http://sourceforge.net/mail/?group_id=170565
Check Sourceforge for updates:
        http://sourceforge.net/projects/xc3sprog/develop

No JTAG Chain found

dpkg -l | grep matrix

result

ii  libmatrixio-creator-hal:armhf  0.3.8                               armhf        Hardware Abstraction Layer for MATRIX.
ii  libmatrixio-creator-hal-dev    0.3.8                               armhf        Hardware Abstraction Layer for MATRIX (headers)
ii  matrixio-creator-init          0.4.17                              armhf        Install scripts that can program the MATRIX Creator FPGA and SAM3 IMU.
ii  matrixio-kernel-modules        0.2.3                               all          Source DKMS for MATRIXIO kernel modules.
ii  matrixio-openocd               1.0.1.002                           armhf        Open on-chip JTAG debug solution for ARM and MIPS systems
ii  matrixio-xc3sprog              1.1.1.003                           armhf        Spartan3, XCF and CPLD JTAG programmer and other utilities.

sudo /usr/share/matrixlabs/matrixio-devices/fpga_info

result

INFO: [/dev/matrixio_regmap] was opened
MATRIX device has not been detected
FPGA IDENTIFY = 0
FPGA VERSION = 10bc4

I appreciate any help

Well, this looks quite similar to my problem.
By now, there is no solution, so I cannot help.

Did it work at all before or is it the first time you try to get it working?

It is the first time I try it. But there was some change during the second setup. The LEDs were OFF now.

It may be a problem of the new RasPi OS version Buster?!

Hmm, I don’t think so, I had this problem before using an older OS, but try for yourself.
Older versions can be found here: http://downloads.raspberrypi.org/raspbian/images/

If I remember correctly, the first one I used was Stretch, and that one worked.

On the other hand, the setup guide says: use the latest version of Rasbian.
https://matrix-io.github.io/matrix-documentation/matrix-creator/device-setup/

@alex70,

I would recommend trying our kit image here. It is based on Raspbian Stretch Desktop and has all of our packages pre-installed. The kit image has a startup sequence in which it makes your LEDs go through the rainbow loop for 10 seconds. If this happens, it means your MATRIX Voice FPGA was appropriately flashed and your issue on Buster could be related to something else.

The MATRIX Voice LEDs are yellow at first due to the FPGA testing image from the manufacturer. Once the FPGA is re-flashed by the matrixio-creator-init package, they will no longer turn yellow. So, that in itself is not a cause for concern.

The JTAG Chain not being found is concerning as this basically means it cannot detect the FPGA. However, we know that it had detected the FPGA previously, given that the LEDs no longer turn yellow which means it had been found and re-flashed.

If the kit image startup sequence does not work for you, please let me know and we will work something out for you.

Best,
Samreen

@Samreen,

I try this kit image already, but it don’t work. I try it again with a new SD Card.
Is this kit also for RasPi 4B working?

Best,
Alex

@Samreen,

I’m sorry to tell you that the kit still not work.

Best,
Alex

@alex70,

I have only tried this kit image with the Raspberry Pi 3/3B+. If you give me some time, I can send you an image with Raspbian Buster and MATRIX packages installed so it can work on your Pi 4B by the end of the week. If that test does not work, I will help you with your device.

Best,
Samreen

@Samreen,

That is fine for me.

Alex

@Samreen,

I start a new setup, but it still don’t work. I’m very disappointed about that.
But there was one progress. The JTAG was found now but the I get still MATRIX device has not been detected.

During Installing MATRIX HAL From Package I notice, that matrixio-kernel-modules is always missing and I install it shown in troubleshooting.

I flash the FPGA and get this:
(the command cd /usr/share/matrixlabs/matrixio-devices/ is missing in the descrition)

cd /usr/share/matrixlabs/matrixio-devices/
xc3sprog -c matrix_voice blob/bscan_spi_s6lx9_ftg256.bit

result

XC3SPROG (c) 2004-2011 xc3sprog project $Rev: 774 $ OS: Linux
Free software: If you contribute nothing, expect nothing!
Feedback on success/failure/enhancement requests:
        http://sourceforge.net/mail/?group_id=170565
Check Sourceforge for updates:
        http://sourceforge.net/projects/xc3sprog/develop

DNA is 0x39d9faefcd67e501
xc3sprog -c matrix_voice -I blob/system_voice.bit

result

XC3SPROG (c) 2004-2011 xc3sprog project $Rev: 774 $ OS: Linux
Free software: If you contribute nothing, expect nothing!
Feedback on success/failure/enhancement requests:
        http://sourceforge.net/mail/?group_id=170565
Check Sourceforge for updates:
        http://sourceforge.net/projects/xc3sprog/develop

JEDEC: c2 20 0x17 0xc2
Found Macronix MX25L Device, Device ID 0x2017
256 bytes/page, 262144 pages = 67108864 bytes total
Verify: Success!

But that was all positive news.

It would be nice if it goes on soon.

Best Regards,
Alex

1 Like

@alex70,

Great news that JTAG was found! This means your MATRIX device is okay. The device still not being detected in MATRIX HAL is very odd but now we know that it is not faulty hardware.

You do not need the MATRIX kernel modules for MATRIX HAL to work. The kernel modules are mainly used for ALSA microphone recording and playback.

In order to test the FPGA+MATRIX HAL, I’ve created a very simple testing image here:

  • OS: Raspbian Buster Lite
  • Packages installed: matrixio-creator-init and MATRIX HAL
  • LED rainbow startup sequence for 10 seconds

Please flash the image onto a microSD card, insert it into your Raspbery Pi, and plug into power. Wait for at least a minute to see if the rainbow LED animation appears for 10 seconds. If your MATRIX device LEDs do light up, that means the FPGA has been successfully flashed and MATRIX HAL is working. You can then setup WiFi on the microSD and try the other MATRIX HAL/Lite examples from the docs.

Best,
Samreen

1 Like

@Samreen,

Thank you for creating this image. I try it twice with two different flashing tools, but it don’t work. I attached the screenshots:

What can I do next?!

Alex

@alex70,

Thank you for trying everything we have suggested so far!

My final troubleshooting suggestion before we DM and discuss different dealings would be to unplug everything from the Pi including power, clean out the Pi GPIOs as well as you can, clean out the MATRIX Voice GPIOs as well as you can, and trying once more. Even more final suggestion, would be to try the MATRIX Voice on a different Pi if that is possible for you (maybe borrow from a friend or makerspace?).

The reason we suggest this is that it is possible a communication port that the device requires such as SPI ports may be blocked, unlikely in software since you are using my image, but perhaps physically by dust/dirt.

If cleaning out the GPIOs and/or trying on a different Pi if you can, doesn’t work, please let me know and I will send you a private message with next steps.

Best,
Samreen

@Samreen,

I have the same idea to try it with my old PiB+ and it works immediately :hugs:
By reconneting the Matix Voice to my new Pi4B it also works without changes to the installation :thinking: I’m happy about this, but it is inexplicable to me because I have often re-inserted the Matrix Voice to the Pi4B.
So the weekend can come. I try then a new image for the Pi4B with the installation guide to see if it still works.

Thanks for support.

Alex

1 Like

@alex70,

Great news! My only idea at this point would be the Pi 4B was somehow failing to accurately flash the FPGA.

Most likely, when you tried the MATRIX Voice with your old Pi (3B+?), it properly flashed the FPGA and therefore, when you switched back to the Pi 4, it worked! The MATRIX Voice retains its FPGA firmware as it has SPI flash memory unless it detects a change in the firmware version (happens when we update our packages, for example).

Still, I have no explanation for why your Pi 4 was not able to accurately flash it, given that we have tested extensively with Pi 4s in general and flashing works for us. It may be specific to your Pi. I’d re-recommend cleaning out the GPIOs :sweat_smile:

Thank you for your patience and looking forward to hearing the results from your weekend tests!

Best,
Samreen

1 Like

@Samreen,

my old Pi is one of the first with this Pins-Connector (PiB+ v1.2 2014)

I could not wait, so I try the examples on both PI’s.

All the everloop works fine on both Pi’s. But the other examples get no values back (every time zero) - for both Pi’s.

I try the commands, to verify the connection to the Matrix Voice Module - everything looks good - both Pi’s show the same (here for Pi B+).

sudo cat /sys/kernel/debug/gpio
gpiochip0: GPIOs 0-53, parent: platform/20200000.gpio, pinctrl-bcm2835:
 gpio-18  (                    |sysfs               ) out hi
 gpio-24  (                    |sysfs               ) out hi
 gpio-25  (                    |sysfs               ) out hi
 gpio-26  (                    |sysfs               ) out hi
 gpio-35  (                    |led1                ) in  hi
 gpio-47  (                    |led0                ) out lo
sudo xc3sprog -j -c sysfsgpio_voice
XC3SPROG (c) 2004-2011 xc3sprog project $Rev: 774 $ OS: Linux
Free software: If you contribute nothing, expect nothing!
Feedback on success/failure/enhancement requests:
        http://sourceforge.net/mail/?group_id=170565
Check Sourceforge for updates:
        http://sourceforge.net/projects/xc3sprog/develop

JTAG loc.:   0  IDCODE: 0x24001093  Desc:                        XC6SLX9 Rev: C  IR length:  6
dpkg -l | grep matrix
ii  libmatrixio-creator-hal:armhf         0.3.8                               armhf        Hardware Abstraction Layer for MATRIX.
ii  libmatrixio-creator-hal-dev           0.3.8                               armhf        Hardware Abstraction Layer for MATRIX (headers)
ii  libswresample3:armhf                  7:4.1.4-1+rpt7~deb10u1              armhf        FFmpeg library for audio resampling, rematrixing etc. - runtime files
ii  matrixio-creator-init                 0.4.17                              armhf        Install scripts that can program the MATRIX Creator FPGA and SAM3 IMU.
ii  matrixio-openocd                      1.0.1.002                           armhf        Open on-chip JTAG debug solution for ARM and MIPS systems
ii  matrixio-xc3sprog                     1.1.1.003                           armhf        Spartan3, XCF and CPLD JTAG programmer and other utilities.
sudo /usr/share/matrixlabs/matrixio-devices/fpga_info
INFO: [/dev/spidev0.0] was opened
FPGA IDENTIFY = 6032bad2
FPGA VERSION = 1000b

What should I do?

Alex

@alex70,

I believe you have the MATRIX Voice which does not have the environmental sensors or IMU, so those examples won’t give you any values. Those examples are meant for our MATRIX Creator board.

How is the microphone example in MATRIX HAL? If that is also having issues, I recommend trying the MATRIX kernel modules following this link. Our mics work very well with them and most voice assistants use the kernel mics so it sets you up for your future projects!

Let me know how it goes.

Best,
Samreen

@Samreen,

Oh no :man_facepalming:, you are right. I have the Matrix Voice and did not pay attention to the fact that these are the examples for the Matrix Creator. I’m sorry.
But otherwise the microphone example works fine :slightly_smiling_face::upside_down_face:.
I try also an old image with my installation and it works fine (only updates).
So the first project can start :hugs:

Thank you, I keep you informed.

Alex

1 Like