Giter VIP home page Giter VIP logo

hintak / seeed-voicecard Goto Github PK

View Code? Open in Web Editor NEW

This project forked from respeaker/seeed-voicecard

180.0 9.0 66.0 1.17 MB

This is an enhancement fork with the explicit aim of supporting current shipping Raspbian/Ubuntu kernels without requiring downgrading. Please donate at https://hintak.github.io/ if it works for you. Use vX.Y branch for kernel version vX.Y

License: GNU General Public License v3.0

Makefile 1.00% Shell 6.87% C 90.87% Python 1.25%

seeed-voicecard's Introduction

seeed-voicecard

The drivers for ReSpeaker Mic Hat, ReSpeaker 4 Mic Array, 6-Mics Circular Array Kit, and 4-Mics Linear Array Kit for Raspberry Pi.

Install seeed-voicecard

Get the seeed voice card source code and install all linux kernel drivers

git clone https://github.com/HinTak/seeed-voicecard
cd seeed-voicecard
sudo ./install.sh
sudo reboot

ReSpeaker Documentation

Up to date documentation for reSpeaker products can be found in Seeed Studio Wiki!

Coherence

Estimate the magnitude squared coherence using Welch’s method. 4-mics-linear-array-kit coherence
Note: 'CO 1-2' means the coherence between channel 1 and channel 2.

# How to get the coherence of the captured audio(a.wav for example).
sudo apt install python-numpy python-scipy python-matplotlib
python tools/coherence.py a.wav

# Requirement of the input audio file:
- format: WAV(Microsoft) signed 16-bit PCM
- channels: >=2

uninstall seeed-voicecard

If you want to upgrade the driver , you need uninstall the driver first.

pi@raspberrypi:~/seeed-voicecard $ sudo ./uninstall.sh 
...
------------------------------------------------------
Please reboot your raspberry pi to apply all settings
Thank you!
------------------------------------------------------

Enjoy !

Technical support

For hardware testing purposes we made a Rasperry Pi OS 5.10.17-v7l+ 32-bit image with reSpeaker drivers pre-installed, which you can download by clicking on this link.

We provide official support for using reSpeaker with the following OS:

  • 32-bit Raspberry Pi OS
  • 64-bit Raspberry Pi OS

And following hardware platforms:

  • Raspberry Pi 3 (all models), Raspberry Pi 4 (all models)

Anything beyond the scope of official support is considered to be community supported. Support for other OS/hardware platforms can be added, provided MOQ requirements can be met.

If you have a technical problem when using reSpeaker with one of the officially supported platforms/OS, feel free to create an issue on Github. For general questions or suggestions, please use Seeed forum.

seeed-voicecard's People

Contributors

aiwintermuteai avatar andremarschalek avatar baorepo avatar fleker avatar gitter-badger avatar hellow554 avatar hhuysqt avatar hintak avatar jerryyip avatar killingjacky avatar lancechentw avatar makermelissa avatar norbusan avatar pcmulder avatar pernat1y avatar pillar1989 avatar psychokiller1888 avatar rotdrop avatar samhithpottem avatar siparker avatar turmary avatar xiongyihui avatar yexiaobo-seeedstudio avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

seeed-voicecard's Issues

Raspberry Pi 5 Support

I tried installing the driver on a fresh bookworm image in Pi 5 and after reboot, the system does not boot anymore. On Pi 4, same OS image everything work well (v6.1).

I would like to get behind Pi 5 support and help to make it happen. This audio chip is super popular and it will be bummer not to have support for Pi 5...

The issue might be related to this:
raspberrypi/linux#5743

Seeed Studio Contributor Program

Hello! HinTak!
It is been a pleasure to meet you! And thank you so much for the continuous update on this repo. We have launched a collaborative program called the Contributor Program - We really hope that you can join us! And improve the wiki regarding the reSpeaker with me:) Here is the detailed assignment and if you are interested, please email me: [email protected]
Really looking forward to the cooperation:D
Best Regards,
Matthew

I cant get it to work unless I use an older kernel version and then lxpanel seems to break

do you have any plans on updating this version of the driver? It seems Seeed themselves wont do any updates to their drivers, but no matter how I've tried - I cant get it to work properly on any version. The only time I got the drivers properly installed was either on the 2021 may version of Raspberry OS or by downgrading the kernel version but then the LXpanel drops and there's no visible menu bar.

dpkg: error processing package linux-headers-rpi-v8 (--configure): dependency problems - leaving unconfigured Errors were encountered while processing: linux-image-6.6.28+rpt-rpi-v8 linux-image-rpi-v8 linux-image-6.6.28+rpt-rpi-2712 linux-headers-6.6.28+rpt-rpi-2712 linux-headers-6.6.28+rpt-rpi-v8 linux-image-rpi-2712 linux-headers-rpi-2712 linux-headers-rpi-v8

`Hit:1 http://deb.debian.org/debian bookworm InRelease
Hit:2 http://deb.debian.org/debian-security bookworm-security InRelease
Hit:3 http://deb.debian.org/debian bookworm-updates InRelease
Hit:4 http://archive.raspberrypi.com/debian bookworm InRelease
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
2 packages can be upgraded. Run 'apt list --upgradable' to see them.
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
raspberrypi-kernel-headers is already the newest version (1:1.20230405-1).
raspberrypi-kernel is already the newest version (1:1.20230405-1).
0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
8 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up linux-image-6.6.28+rpt-rpi-v8 (1:6.6.28-1+rpt1) ...
/etc/kernel/postinst.d/dkms:
dkms: running auto installation service for kernel 6.6.28+rpt-rpi-v8.
Sign command: /lib/modules/6.6.28+rpt-rpi-v8/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub

Building module:
Cleaning build area...
make -j4 KERNELRELEASE=6.6.28+rpt-rpi-v8 -C /lib/modules/6.6.28+rpt-rpi-v8/build M=/var/lib/dkms/seeed-voicecard/0.3/build...(bad exit status: 2)
Error! Bad return status for module build on kernel: 6.6.28+rpt-rpi-v8 (aarch64)
Consult /var/lib/dkms/seeed-voicecard/0.3/build/make.log for more information.
Error! One or more modules failed to install during autoinstall.
Refer to previous errors for more information.
dkms: autoinstall for kernel: 6.6.28+rpt-rpi-v8 failed!
run-parts: /etc/kernel/postinst.d/dkms exited with return code 11
dpkg: error processing package linux-image-6.6.28+rpt-rpi-v8 (--configure):
installed linux-image-6.6.28+rpt-rpi-v8 package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of linux-image-rpi-v8:
linux-image-rpi-v8 depends on linux-image-6.6.28+rpt-rpi-v8 (= 1:6.6.28-1+rpt1); however:
Package linux-image-6.6.28+rpt-rpi-v8 is not configured yet.

dpkg: error processing package linux-image-rpi-v8 (--configure):
dependency problems - leaving unconfigured
Setting up linux-image-6.6.28+rpt-rpi-2712 (1:6.6.28-1+rpt1) ...
I: /initrd.img.old is now a symlink to boot/initrd.img-6.6.28+rpt-rpi-2712
/etc/kernel/postinst.d/dkms:
dkms: running auto installation service for kernel 6.6.28+rpt-rpi-2712.
Sign command: /lib/modules/6.6.28+rpt-rpi-2712/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub

Building module:
Cleaning build area...
make -j4 KERNELRELEASE=6.6.28+rpt-rpi-2712 -C /lib/modules/6.6.28+rpt-rpi-2712/build M=/var/lib/dkms/seeed-voicecard/0.3/build...(bad exit status: 2)
Error! Bad return status for module build on kernel: 6.6.28+rpt-rpi-2712 (aarch64)
Consult /var/lib/dkms/seeed-voicecard/0.3/build/make.log for more information.
Error! One or more modules failed to install during autoinstall.
Refer to previous errors for more information.
dkms: autoinstall for kernel: 6.6.28+rpt-rpi-2712 failed!
run-parts: /etc/kernel/postinst.d/dkms exited with return code 11
dpkg: error processing package linux-image-6.6.28+rpt-rpi-2712 (--configure):
installed linux-image-6.6.28+rpt-rpi-2712 package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of linux-headers-6.6.28+rpt-rpi-2712:
linux-headers-6.6.28+rpt-rpi-2712 depends on linux-image-6.6.28+rpt-rpi-2712 (= 1:6.6.28-1+rpt1) | linux-image-6.6.28+rpt-rpi-2712-unsigned (= 1:6.6.28-1+rpt1); however:
Package linux-image-6.6.28+rpt-rpi-2712 is not configured yet.
Package linux-image-6.6.28+rpt-rpi-2712-unsigned is not installed.

dpkg: error processing package linux-headers-6.6.28+rpt-rpi-2712 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-headers-6.6.28+rpt-rpi-v8:
linux-headers-6.6.28+rpt-rpi-v8 depends on linux-image-6.6.28+rpt-rpi-v8 (= 1:6.6.28-1+rpt1) | linux-image-6.6.28+rpt-rpi-v8-unsigned (= 1:6.6.28-1+rpt1); however:
Package linux-image-6.6.28+rpt-rpi-v8 is not configured yet.
Package linux-image-6.6.28+rpt-rpi-v8-unsigned is not installed.

dpkg: error processing package linux-headers-6.6.28+rpt-rpi-v8 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-image-rpi-2712:
linux-image-rpi-2712 depends on linux-image-6.6.28+rpt-rpi-2712 (= 1:6.6.28-1+rpt1); however:
Package linux-image-6.6.28+rpt-rpi-2712 is not configured yet.

dpkg: error processing package linux-image-rpi-2712 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-headers-rpi-2712:
linux-headers-rpi-2712 depends on linux-headers-6.6.28+rpt-rpi-2712 (= 1:6.6.28-1+rpt1); however:
Package linux-headers-6.6.28+rpt-rpi-2712 is not configured yet.

dpkg: error processing package linux-headers-rpi-2712 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-headers-rpi-v8:
linux-headers-rpi-v8 depends on linux-headers-6.6.28+rpt-rpi-v8 (= 1:6.6.28-1+rpt1); however:
Package linux-headers-6.6.28+rpt-rpi-v8 is not configured yet.

dpkg: error processing package linux-headers-rpi-v8 (--configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
linux-image-6.6.28+rpt-rpi-v8
linux-image-rpi-v8
linux-image-6.6.28+rpt-rpi-2712
linux-headers-6.6.28+rpt-rpi-2712
linux-headers-6.6.28+rpt-rpi-v8
linux-image-rpi-2712
linux-headers-rpi-2712
linux-headers-rpi-v8
E: Sub-process /usr/bin/dpkg returned an error code (1)
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Note, selecting 'gcc' instead of 'gcc-aarch64-linux-gnu'
gcc is already the newest version (4:12.2.0-3).
0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
8 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up linux-image-6.6.28+rpt-rpi-v8 (1:6.6.28-1+rpt1) ...
/etc/kernel/postinst.d/dkms:
dkms: running auto installation service for kernel 6.6.28+rpt-rpi-v8.
Sign command: /lib/modules/6.6.28+rpt-rpi-v8/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub

Building module:
Cleaning build area...
make -j4 KERNELRELEASE=6.6.28+rpt-rpi-v8 -C /lib/modules/6.6.28+rpt-rpi-v8/build M=/var/lib/dkms/seeed-voicecard/0.3/build...(bad exit status: 2)
Error! Bad return status for module build on kernel: 6.6.28+rpt-rpi-v8 (aarch64)
Consult /var/lib/dkms/seeed-voicecard/0.3/build/make.log for more information.
Error! One or more modules failed to install during autoinstall.
Refer to previous errors for more information.
dkms: autoinstall for kernel: 6.6.28+rpt-rpi-v8 failed!
run-parts: /etc/kernel/postinst.d/dkms exited with return code 11
dpkg: error processing package linux-image-6.6.28+rpt-rpi-v8 (--configure):
installed linux-image-6.6.28+rpt-rpi-v8 package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of linux-image-rpi-v8:
linux-image-rpi-v8 depends on linux-image-6.6.28+rpt-rpi-v8 (= 1:6.6.28-1+rpt1); however:
Package linux-image-6.6.28+rpt-rpi-v8 is not configured yet.

dpkg: error processing package linux-image-rpi-v8 (--configure):
dependency problems - leaving unconfigured
Setting up linux-image-6.6.28+rpt-rpi-2712 (1:6.6.28-1+rpt1) ...
I: /initrd.img.old is now a symlink to boot/initrd.img-6.6.28+rpt-rpi-2712
/etc/kernel/postinst.d/dkms:
dkms: running auto installation service for kernel 6.6.28+rpt-rpi-2712.
Sign command: /lib/modules/6.6.28+rpt-rpi-2712/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub

Building module:
Cleaning build area...
make -j4 KERNELRELEASE=6.6.28+rpt-rpi-2712 -C /lib/modules/6.6.28+rpt-rpi-2712/build M=/var/lib/dkms/seeed-voicecard/0.3/build...(bad exit status: 2)
Error! Bad return status for module build on kernel: 6.6.28+rpt-rpi-2712 (aarch64)
Consult /var/lib/dkms/seeed-voicecard/0.3/build/make.log for more information.
Error! One or more modules failed to install during autoinstall.
Refer to previous errors for more information.
dkms: autoinstall for kernel: 6.6.28+rpt-rpi-2712 failed!
run-parts: /etc/kernel/postinst.d/dkms exited with return code 11
dpkg: error processing package linux-image-6.6.28+rpt-rpi-2712 (--configure):
installed linux-image-6.6.28+rpt-rpi-2712 package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of linux-headers-6.6.28+rpt-rpi-2712:
linux-headers-6.6.28+rpt-rpi-2712 depends on linux-image-6.6.28+rpt-rpi-2712 (= 1:6.6.28-1+rpt1) | linux-image-6.6.28+rpt-rpi-2712-unsigned (= 1:6.6.28-1+rpt1); however:
Package linux-image-6.6.28+rpt-rpi-2712 is not configured yet.
Package linux-image-6.6.28+rpt-rpi-2712-unsigned is not installed.

dpkg: error processing package linux-headers-6.6.28+rpt-rpi-2712 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-headers-6.6.28+rpt-rpi-v8:
linux-headers-6.6.28+rpt-rpi-v8 depends on linux-image-6.6.28+rpt-rpi-v8 (= 1:6.6.28-1+rpt1) | linux-image-6.6.28+rpt-rpi-v8-unsigned (= 1:6.6.28-1+rpt1); however:
Package linux-image-6.6.28+rpt-rpi-v8 is not configured yet.
Package linux-image-6.6.28+rpt-rpi-v8-unsigned is not installed.

dpkg: error processing package linux-headers-6.6.28+rpt-rpi-v8 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-image-rpi-2712:
linux-image-rpi-2712 depends on linux-image-6.6.28+rpt-rpi-2712 (= 1:6.6.28-1+rpt1); however:
Package linux-image-6.6.28+rpt-rpi-2712 is not configured yet.

dpkg: error processing package linux-image-rpi-2712 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-headers-rpi-2712:
linux-headers-rpi-2712 depends on linux-headers-6.6.28+rpt-rpi-2712 (= 1:6.6.28-1+rpt1); however:
Package linux-headers-6.6.28+rpt-rpi-2712 is not configured yet.

dpkg: error processing package linux-headers-rpi-2712 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-headers-rpi-v8:
linux-headers-rpi-v8 depends on linux-headers-6.6.28+rpt-rpi-v8 (= 1:6.6.28-1+rpt1); however:
Package linux-headers-6.6.28+rpt-rpi-v8 is not configured yet.

dpkg: error processing package linux-headers-rpi-v8 (--configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
linux-image-6.6.28+rpt-rpi-v8
linux-image-rpi-v8
linux-image-6.6.28+rpt-rpi-2712
linux-headers-6.6.28+rpt-rpi-2712
linux-headers-6.6.28+rpt-rpi-v8
linux-image-rpi-2712
linux-headers-rpi-2712
linux-headers-rpi-v8
E: Sub-process /usr/bin/dpkg returned an error code (1)
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
E: Unable to locate package linux-raspi
E: Unable to locate package linux-headers-raspi
E: Unable to locate package linux-image-raspi
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
dkms is already the newest version (3.0.10-8+deb12u1).
git is already the newest version (1:2.39.2-1.1).
i2c-tools is already the newest version (4.3-2+b3).
libasound2-plugins is already the newest version (1.2.7.1-1).
0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
8 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up linux-image-6.6.28+rpt-rpi-v8 (1:6.6.28-1+rpt1) ...
/etc/kernel/postinst.d/dkms:
dkms: running auto installation service for kernel 6.6.28+rpt-rpi-v8.
Sign command: /lib/modules/6.6.28+rpt-rpi-v8/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub

Building module:
Cleaning build area...
make -j4 KERNELRELEASE=6.6.28+rpt-rpi-v8 -C /lib/modules/6.6.28+rpt-rpi-v8/build M=/var/lib/dkms/seeed-voicecard/0.3/build...(bad exit status: 2)
Error! Bad return status for module build on kernel: 6.6.28+rpt-rpi-v8 (aarch64)
Consult /var/lib/dkms/seeed-voicecard/0.3/build/make.log for more information.
Error! One or more modules failed to install during autoinstall.
Refer to previous errors for more information.
dkms: autoinstall for kernel: 6.6.28+rpt-rpi-v8 failed!
run-parts: /etc/kernel/postinst.d/dkms exited with return code 11
dpkg: error processing package linux-image-6.6.28+rpt-rpi-v8 (--configure):
installed linux-image-6.6.28+rpt-rpi-v8 package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of linux-image-rpi-v8:
linux-image-rpi-v8 depends on linux-image-6.6.28+rpt-rpi-v8 (= 1:6.6.28-1+rpt1); however:
Package linux-image-6.6.28+rpt-rpi-v8 is not configured yet.

dpkg: error processing package linux-image-rpi-v8 (--configure):
dependency problems - leaving unconfigured
Setting up linux-image-6.6.28+rpt-rpi-2712 (1:6.6.28-1+rpt1) ...
I: /initrd.img.old is now a symlink to boot/initrd.img-6.6.28+rpt-rpi-2712
/etc/kernel/postinst.d/dkms:
dkms: running auto installation service for kernel 6.6.28+rpt-rpi-2712.
Sign command: /lib/modules/6.6.28+rpt-rpi-2712/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub

Building module:
Cleaning build area...
make -j4 KERNELRELEASE=6.6.28+rpt-rpi-2712 -C /lib/modules/6.6.28+rpt-rpi-2712/build M=/var/lib/dkms/seeed-voicecard/0.3/build...(bad exit status: 2)
Error! Bad return status for module build on kernel: 6.6.28+rpt-rpi-2712 (aarch64)
Consult /var/lib/dkms/seeed-voicecard/0.3/build/make.log for more information.
Error! One or more modules failed to install during autoinstall.
Refer to previous errors for more information.
dkms: autoinstall for kernel: 6.6.28+rpt-rpi-2712 failed!
run-parts: /etc/kernel/postinst.d/dkms exited with return code 11
dpkg: error processing package linux-image-6.6.28+rpt-rpi-2712 (--configure):
installed linux-image-6.6.28+rpt-rpi-2712 package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of linux-headers-6.6.28+rpt-rpi-2712:
linux-headers-6.6.28+rpt-rpi-2712 depends on linux-image-6.6.28+rpt-rpi-2712 (= 1:6.6.28-1+rpt1) | linux-image-6.6.28+rpt-rpi-2712-unsigned (= 1:6.6.28-1+rpt1); however:
Package linux-image-6.6.28+rpt-rpi-2712 is not configured yet.
Package linux-image-6.6.28+rpt-rpi-2712-unsigned is not installed.

dpkg: error processing package linux-headers-6.6.28+rpt-rpi-2712 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-headers-6.6.28+rpt-rpi-v8:
linux-headers-6.6.28+rpt-rpi-v8 depends on linux-image-6.6.28+rpt-rpi-v8 (= 1:6.6.28-1+rpt1) | linux-image-6.6.28+rpt-rpi-v8-unsigned (= 1:6.6.28-1+rpt1); however:
Package linux-image-6.6.28+rpt-rpi-v8 is not configured yet.
Package linux-image-6.6.28+rpt-rpi-v8-unsigned is not installed.

dpkg: error processing package linux-headers-6.6.28+rpt-rpi-v8 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-image-rpi-2712:
linux-image-rpi-2712 depends on linux-image-6.6.28+rpt-rpi-2712 (= 1:6.6.28-1+rpt1); however:
Package linux-image-6.6.28+rpt-rpi-2712 is not configured yet.

dpkg: error processing package linux-image-rpi-2712 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-headers-rpi-2712:
linux-headers-rpi-2712 depends on linux-headers-6.6.28+rpt-rpi-2712 (= 1:6.6.28-1+rpt1); however:
Package linux-headers-6.6.28+rpt-rpi-2712 is not configured yet.

dpkg: error processing package linux-headers-rpi-2712 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-headers-rpi-v8:
linux-headers-rpi-v8 depends on linux-headers-6.6.28+rpt-rpi-v8 (= 1:6.6.28-1+rpt1); however:
Package linux-headers-6.6.28+rpt-rpi-v8 is not configured yet.

dpkg: error processing package linux-headers-rpi-v8 (--configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
linux-image-6.6.28+rpt-rpi-v8
linux-image-rpi-v8
linux-image-6.6.28+rpt-rpi-2712
linux-headers-6.6.28+rpt-rpi-2712
linux-headers-6.6.28+rpt-rpi-v8
linux-image-rpi-2712
linux-headers-rpi-2712
linux-headers-rpi-v8
E: Sub-process /usr/bin/dpkg returned an error code (1)
Module seeed-voicecard-0.3 for kernel 6.1.0-rpi8-rpi-2712 (aarch64).
Before uninstall, this module version was ACTIVE on this kernel.

snd-soc-wm8960.ko.xz:

  • Uninstallation
    • Deleting from: /lib/modules/6.1.0-rpi8-rpi-2712/updates/dkms/
  • Original module
    • No original module was found for this module on this kernel.
    • Use the dkms install command to reinstall any previous module version.

snd-soc-ac108.ko.xz:

  • Uninstallation
    • Deleting from: /lib/modules/6.1.0-rpi8-rpi-2712/updates/dkms/
  • Original module
    • No original module was found for this module on this kernel.
    • Use the dkms install command to reinstall any previous module version.

snd-soc-seeed-voicecard.ko.xz:

  • Uninstallation
    • Deleting from: /lib/modules/6.1.0-rpi8-rpi-2712/updates/dkms/
  • Original module
    • No original module was found for this module on this kernel.
    • Use the dkms install command to reinstall any previous module version.
      depmod....
      Deleting module seeed-voicecard-0.3 completely from the DKMS tree.
      Creating symlink /var/lib/dkms/seeed-voicecard/0.3/source -> /usr/src/seeed-voicecard-0.3
      Sign command: /usr/lib/linux-kbuild-6.1/scripts/sign-file
      Signing key: /var/lib/dkms/mok.key
      Public certificate (MOK): /var/lib/dkms/mok.pub

Building module:
Cleaning build area...
make -j4 KERNELRELEASE=6.1.0-rpi8-rpi-2712 -C /lib/modules/6.1.0-rpi8-rpi-2712/build M=/var/lib/dkms/seeed-voicecard/0.3/build...(bad exit status: 2)
Error! Bad return status for module build on kernel: 6.1.0-rpi8-rpi-2712 (aarch64)
Consult /var/lib/dkms/seeed-voicecard/0.3/build/make.log for more information.
mkdir: cannot create directory '/etc/voicecard': File exists
git init
Reinitialized existing Git repository in /etc/voicecard/.git/
git add --all
git commit -m "origin configures"
On branch master
nothing to commit, working tree clean

Please reboot your raspberry pi to apply all settings
Enjoy!

`

2-Mic Hat doesn't work on Raspberry Pi 4 Model B

Hi:

I encountered such issue when running command from official document to test the recording function:

hongfeij@raspberrypi:~ $ arecord -l
**** List of CAPTURE Hardware Devices ****
card 3: seeed2micvoicec [seeed-2mic-voicecard], device 0: fe203000.i2s-wm8960-hifi wm8960-hifi-0 [fe203000.i2s-wm8960-hifi wm8960-hifi-0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

hongfeij@raspberrypi:~ $ arecord -D "plughw:3,0" -f S16_LE -r 16000 -d 5 -t wav test.wav
Recording WAVE 'test.wav' : Signed 16 bit Little Endian, Rate 16000 Hz, Mono
**arecord: set_params:1416: Unable to install hw params:**
ACCESS:  RW_INTERLEAVED
FORMAT:  S16_LE
SUBFORMAT:  STD
SAMPLE_BITS: 16
FRAME_BITS: 16
CHANNELS: 1
RATE: 16000
PERIOD_TIME: 125000
PERIOD_SIZE: 2000
PERIOD_BYTES: 4000
PERIODS: 4
BUFFER_TIME: 500000
BUFFER_SIZE: 8000
BUFFER_BYTES: 16000
TICK_TIME: 0

Any clue about the reason and solution?

Issue: Support for latest raspios bookworm

Hey everyone, I'm unable to install the 4mic-array drivers using latest raspios (raspios_lite_arm64-bookworm).
https://downloads.raspberrypi.com/raspios_lite_arm64/images/.../2024-03-15-raspios-bookworm-arm64-lite.img.xz.

Overview

I'm getting the following message when running the install script from the 6.6 branch. Seems like dkms and i2c-tools has not installation candidates on raspios-bookworm. I also tried installing: https://github.com/respeaker/seeed-voicecard
Please let me know if anyone is facing something similar,

uname -r
6.6.20+rpt-rpi-v8
git clone -b v6.6 https://github.com/HinTak/seeed-voicecard
cd seeed-voicecard && sudo ./install.sh

...

Package i2c-tools is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

Package dkms is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'dkms' has no installation candidate
E: Package 'i2c-tools' has no installation candidate
./install.sh: line 151: dkms: command not found
./install.sh: line 153: dkms: command not found
setup git config
git init
hint: Using 'master' as the name for the initial branch. This default branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint: 
hint: 	git config --global init.defaultBranch <name>
hint: 
hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
hint: 'development'. The just-created branch can be renamed via this command:
hint: 
hint: 	git branch -m <name>
Initialized empty Git repository in /etc/voicecard/.git/
git add --all
git commit -m "origin configures"
[master (root-commit) d3535f3] origin configures
 7 files changed, 1482 insertions(+)
 create mode 100644 ac108_6mic.state
 create mode 100644 ac108_asound.state
 create mode 100644 asound_2mic.conf
 create mode 100644 asound_4mic.conf
 create mode 100644 asound_6mic.conf
 create mode 100644 dkms.conf
 create mode 100644 wm8960_asound.state
Created symlink /etc/systemd/system/sysinit.target.wants/seeed-voicecard.service → /lib/systemd/system/seeed-voicecard.service.
------------------------------------------------------
Please reboot your raspberry pi to apply all settings
Enjoy!

After rebooting, I'm getting an empty list of capture hardware devices

$ arecord -l
$ **** List of CAPTURE Hardware Devices ****

[FR] Refactor to Debian packaging

Hi @HinTak - great work on keeping things up to date!

There's one thing that bothers me a little. The current structure, while sticks closely to the original Seeed repo, is not really suitable for long term support, or easy installation, especially with all the separate branches for different kernel versions.

I'd like to recommend a refactor that would introduce a proper build system to create Debian packages. This would allow a number of convenience features:

  • Easier distribution - APT repos can easily hosted on GitHub, and users wouldn't need to run install/uninstall scripts via sudo. This would also allow for easier updates.
  • More fine-grained installations. By packaging components separately (e.g. a a10x-dev package containing the a10x.h file, separate DKMS driver packages for a101, a108 and wm8960, as well as a separate seed-voicecard DKMS package, culminating in semi-meta packages for the various card models), one could install just what is needed to get their device working.
  • Support for multiple kernel versions in the same branch. No more dozen+ branches for each kernel versions, but rather each module would have multiple subfolders, targeting different kernel versions, keeping everything in one place yet still separate (e.g. a108/src/6.2/a108.[hc] etc.)
  • Automated packaging using GHA Workflows. Just update the files, merge into main, tag the version, and bam, new packages published.
  • Remove the need of manual compilation and manual handling of overlays, etc., by having the Debian package take care of it
  • The new folder architecture could then be used for other distros' package builders as well, making it possible to deploy packaging for Arch etc.
  • Remove the need to maintain the hacky install script, by breaking it down into separate parts for the components, making maintenance much simpler

Ideally this would result in the following packages:

  • seeed-a10x-dev - containing only the a10x.h file to be used for both the build process and development
  • seeed-a101-dkms - the DKMS drivers for the A101
  • seeed-a108-dkms - the DKMS drivers for the A108
  • seeed-wm8960-dkms - the DKMS driver for the WM8960
  • seeed-voicecard-2mic - package containing the files necessary for the 2-mic voicecard (DTBO, ALSA config and state), with a DependsOn set as
  • seeed-voicecard-4mic - package for the 4-mic voice card
  • seeed-voicecard-6mic/8mic - same as above

And with a bit of tinkering, the DKMS install script could be modified to even match the appropriate kernel X.Y folder within and compile that code (although I think version-specific changes should be done within the source, e.g. how it's done at https://github.com/HinTak/seeed-voicecard/blob/v6.1/ac108.c#L1328-L1332)

Cant get 4-mic hat to record

Hello @HinTak I appreacite you taking the time to continue development on seed devices. I have been scouring the web for the past week trying to get my 4-mic hat array working on the bullseye rasp OS, Ive tried both 32 and 64 bit versions, I finally decided to stick with the 32 bit hoping for better compatibility but to now avail. I am using your repo now and although the system does recognize the drivers I cant for the life of me find a proper command to get it to record any audio.

I even tried to pump data into chatgpt since it is aware of respeaker and its products it claims but that gpt is becoming dumber and dumber by the day it seems.
Here are a few details to my setup:
arecord -L gives me

null
    Discard all samples (playback) or generate zero samples (capture)
sysdefault
    Default Audio Device
lavrate
    Rate Converter Plugin Using Libav/FFmpeg Library
samplerate
    Rate Converter Plugin Using Samplerate Library
speexrate
    Rate Converter Plugin Using Speex Resampler
jack
    JACK Audio Connection Kit
oss
    Open Sound System
pulse
    PulseAudio Sound Server
speex
    Plugin using Speex DSP (resample, agc, denoise, echo, dereverb)
upmix
    Plugin for channel upmix (4,6,8)
vdownmix
    Plugin for channel downmix (stereo) with a simple spacialization
default
    Playback/recording through the PulseAudio sound server
speaker
dmixer
array
usbstream:CARD=vc4hdmi
    vc4-hdmi
    USB Stream Output
usbstream:CARD=Headphones
    bcm2835 Headphones
    USB Stream Output
hw:CARD=ArrayUAC10,DEV=0
    ReSpeaker 4 Mic Array (UAC1.0), USB Audio
    Direct hardware device without any conversions
plughw:CARD=ArrayUAC10,DEV=0
    ReSpeaker 4 Mic Array (UAC1.0), USB Audio
    Hardware device with all software conversions
sysdefault:CARD=ArrayUAC10
    ReSpeaker 4 Mic Array (UAC1.0), USB Audio
    Default Audio Device
front:CARD=ArrayUAC10,DEV=0
    ReSpeaker 4 Mic Array (UAC1.0), USB Audio
    Front output / input
dsnoop:CARD=ArrayUAC10,DEV=0
    ReSpeaker 4 Mic Array (UAC1.0), USB Audio
    Direct sample snooping device
usbstream:CARD=ArrayUAC10
    ReSpeaker 4 Mic Array (UAC1.0)
    USB Stream Output

I noticed when I try to run a simple arecord command i get a Channels count non available
I did learn that when i use 6 channels the command get a bit farther

chatgpt suggested i create a .asoundrc file with this for its contents

pcm.!default {
    type asym
    playback.pcm "speaker"
    capture.pcm "dmixer"
}

pcm.speaker {
    type plug
    slave.pcm "hw:CARD=Headphones,DEV=0"
}

pcm.dmixer {
    type dmix
    ipc_key 1024
    slave {
        pcm "hw:CARD=ArrayUAC10,DEV=0"
        period_time 0
        period_size 1024
        buffer_size 8192
        rate 16000
    }
    bindings {
        0 0
        1 1
    }
}

ctl.dmixer {
    type hw
    card ArrayUAC10
}

pcm.array {
    type plug
    slave.pcm "hw:CARD=ArrayUAC10,DEV=0"
}

Ive tried to install audacity as one forum reply suggested but even then it can see the respeaker device in the dropdowns but when i hit the record button it goes from "stopped" to quickly record immediately back to stopped. I am stumped and ready to toss this thing in the trash im getting so frustrated trying to get it working on this PI. when I first got the device i plugged it into my windows machine and it works great. so I know the device works.

any tips or help would be most appreciated

oh i also had gpt help make me a script to check audio devices using pyaudio:

import pyaudio
import wave


def record_audio(device_index, file_path, duration=5):
    p = pyaudio.PyAudio()

    try:
        stream = p.open(
            format=pyaudio.paInt16,
            channels=4,  # Adjust channels based on the number of microphones
            rate=16000,  # Adjust rate based on the max sample rate
            input=True,
            input_device_index=device_index,
            frames_per_buffer=1024,
        )

        print("Recording...")
        frames = []
        for i in range(0, int(16000 / 1024 * duration)):
            data = stream.read(1024)
            frames.append(data)

        print("Recording done.")
        stream.stop_stream()
        stream.close()

        wf = wave.open(file_path, "wb")
        wf.setnchannels(4)  # Adjust channels based on the number of microphones
        wf.setsampwidth(pyaudio.PyAudio().get_sample_size(pyaudio.paInt16))
        wf.setframerate(16000)  # Adjust rate based on the max sample rate
        wf.writeframes(b"".join(frames))
        wf.close()

    finally:
        p.terminate()


if __name__ == "__main__":
    # Set the index of your ReSpeaker 4-Mic Array
    respeaker_index = 2  # Adjust this based on the correct index for your device

    # Record audio and save to a file
    record_audio(respeaker_index, "test.wav")

but it spits out a bunch of garble i dont really understand and when entere into gpt it thinks im trying to forge id numbers or some stupid response it gave me lol

ALSA lib pcm_asym.c:105:(_snd_pcm_asym_open) capture slave is not defined
ALSA lib confmisc.c:1369:(snd_func_refer) Unable to find definition 'cards.0.pcm.front.0:CARD=0'
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5703:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM front
ALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear
ALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe
ALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side
ALSA lib confmisc.c:1369:(snd_func_refer) Unable to find definition 'cards.0.pcm.surround51.0:CARD=0'
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5703:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM surround21
ALSA lib confmisc.c:1369:(snd_func_refer) Unable to find definition 'cards.0.pcm.surround51.0:CARD=0'
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5703:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM surround21
ALSA lib confmisc.c:1369:(snd_func_refer) Unable to find definition 'cards.0.pcm.surround40.0:CARD=0'
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5703:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM surround40
ALSA lib confmisc.c:1369:(snd_func_refer) Unable to find definition 'cards.0.pcm.surround51.0:CARD=0'
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5703:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM surround41
ALSA lib confmisc.c:1369:(snd_func_refer) Unable to find definition 'cards.0.pcm.surround51.0:CARD=0'
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5703:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM surround50
ALSA lib confmisc.c:1369:(snd_func_refer) Unable to find definition 'cards.0.pcm.surround51.0:CARD=0'
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5703:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM surround51
ALSA lib confmisc.c:1369:(snd_func_refer) Unable to find definition 'cards.0.pcm.surround71.0:CARD=0'
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5703:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM surround71

------ not of the same for 3 more pages -------
and at the bottom this stuff

Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
JackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock
JackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock
Expression 'r' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2097
Expression 'PaAlsaStreamComponent_FinishConfigure( &self->capture, hwParamsCapture, inParams, self->primeBuffers, realSr, inputLatency )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2730
Expression 'PaAlsaStream_Configure( stream, inputParameters, outputParameters, sampleRate, framesPerBuffer, &inputLatency, &outputLatency, &hostBufferSizeMode )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2842
Traceback (most recent call last):
  File "/home/rhasspy/./micCheck1.py", line 44, in <module>
    record_audio(respeaker_index, "test.wav")
  File "/home/rhasspy/./micCheck1.py", line 9, in record_audio
    stream = p.open(
             ^^^^^^^
  File "/usr/local/lib/python3.11/dist-packages/pyaudio/__init__.py", line 639, in open
    stream = PyAudio.Stream(self, *args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/dist-packages/pyaudio/__init__.py", line 441, in __init__
    self._stream = pa.open(**arguments)
                   ^^^^^^^^^^^^^^^^^^^^
OSError: [Errno -9999] Unanticipated host error

Have you seen or come across any of this or am I cursed? lol :(

Installation script

Not an issue, but I've created an install script that's much less painful than the original (currently just for kernel 6.1):

#!/usr/bin/env bash

# Installs drivers for the ReSpeaker 2mic and 4mic HATs on Raspberry Pi OS.
# Must be run with sudo.
# Requires: curl raspberrypi-kernel-headers dkms i2c-tools libasound2-plugins alsa-utils

set -eo pipefail

apt-get update
apt-get install --no-install-recommends --yes \
    curl raspberrypi-kernel-headers dkms i2c-tools libasound2-plugins alsa-utils

temp_dir="$(mktemp -d)"

function finish {
   rm -rf "${temp_dir}"
}

trap finish EXIT

pushd "${temp_dir}"

# Download source code to temporary directory
# NOTE: There are different branches in the repo for different kernel versions.
# We use v6.1 here.
echo 'Downloading source code'
curl -L -o - 'https://github.com/HinTak/seeed-voicecard/archive/refs/heads/v6.1.tar.gz' | \
    tar -xzf -

cd seeed-voicecard-6.1/

# 1. Build kernel module
echo 'Building kernel module'
ver='0.3'
mod='seeed-voicecard'
src='./'
kernel="$(uname -r)"
marker='0.0.0'

mkdir -p "/usr/src/${mod}-${ver}"
cp -a "${src}"/* "/usr/src/${mod}-${ver}/"

dkms add -m "${mod}" -v "${ver}"
dkms build -k "${kernel}" -m "${mod}" -v "${ver}" && {
    dkms install --force -k "${kernel}" -m "${mod}" -v "${ver}"
}

mkdir -p "/var/lib/dkms/${mod}/${ver}/${marker}"

# 2. Install kernel module and configure
echo 'Updating boot configuration'
config='/boot/config.txt'

cp seeed-*-voicecard.dtbo /boot/overlays
grep -q "^snd-soc-ac108$" /etc/modules || echo "snd-soc-ac108" >> /etc/modules
sed -i -e 's:#dtparam=i2c_arm=on:dtparam=i2c_arm=on:g' "${config}"
echo "dtoverlay=i2s-mmap" >> "${config}"
echo "dtparam=i2s=on" >> "${config}"
mkdir -p /etc/voicecard
cp *.conf *.state /etc/voicecard
cp seeed-voicecard /usr/bin/
cp seeed-voicecard.service /lib/systemd/system/
systemctl enable --now seeed-voicecard.service

echo 'Done. Please reboot the system.'
popd

Integration with Pipewire?

Do you have any suggestions on how to properly integrate this 'sound card' with pipewire?

For example, the installation creates a /etc/asound.conf file, but for Pipewire I've seen it recommended to delete that file and install pipewire-alsa.

Since Pipewire is fairly new to me I thought I'd ask.

Missing taskbar issue

Hi there,
I recently bought a audio hat 4 mic linear array board. I've installed the git repository from the actual seeed site but they refuse to install due to them being outdated. I found this reposity to help my previous issue but when i install the drivers from this reposity, my taskbar seems to disappear. I have to have the taskbar present for my intended use of the raspberry pi. Please can someone help me out

4-Mic Array "only" 12 bit ~65dB dynamic !? AC108 delivers 24 bit, why does the driver throw 12 bit away?

I got the 4-Mic Array on a Pi Zero 2 running, with your latest 6.1 branch. I used the modifications of: JaPhoton posted here: respeaker#309 that fixed the problem, that restarting ends up sometimes of mixed channel order.
But now i record, in audacity, or arecord (S32_LE) but it ends up that only 12 bit are provided !? (audacity smallest nonzero value is 0.0004) I checked with the Osci and see that the AC108 delivers 4 Channel 24 bit, so it looks as the driver ac108.c ?? throws the lower 12 bit away ???

Which repo?

thanks for maintaining this drivers, you're a saint!

Which repo should we use? The readme for this one points to https://github.com/HinTak/seeed-voicecard and the readme over there points to the original unmaintained repo.

It seems like this repo should be the one to use since you've merged in the latest mainline to the master branch?

Bad return status for module build on kernel: 6.6.20+rpt-rpi-v8 (aarch64)

When attempting to run the installation script for a ReSpeaker 6 mic array (gen 1), I'm seeing the following errors on a Raspberry Pi 4B model running the latest bookworm Lite OS.

Building module:
Cleaning build area...
make -j4 KERNELRELEASE=6.6.20+rpt-rpi-v8 -C /lib/modules/6.6.20+rpt-rpi-v8/build M=/var/lib/dkms/seeed-voicecard/0.3/build....(bad exit status: 2)
Error! Bad return status for module build on kernel: 6.6.20+rpt-rpi-v8 (aarch64)
Consult /var/lib/dkms/seeed-voicecard/0.3/build/make.log for more information.
mkdir: cannot create directory ‘/etc/voicecard’: File exists
git init
Reinitialized existing Git repository in /etc/voicecard/.git/
git add --all
git commit -m "origin configures"
On branch master
nothing to commit, working tree clean
------------------------------------------------------
Please reboot your raspberry pi to apply all settings
Enjoy!

Your loaded kernal version is 6.1.21

WARNING: Your loaded kernal version is 6.1.21
Not matching the update version.
Kernal was updated, but new kernal was not loaded yet.
Please reboot your machine AND THEN run the script again.

I rebooted and ran many times but keeping getting the same result.

I am using Rp 4B Model, and OS 64-bit Legacy 2023/5/03 Bullseye

Does anyone encounter the same issue, and have successfully solved it?

6-mic doesn't work on Raspberry PI 5

Hi, all!

I've applied fix to I2C issues:
sudo rpi-update pulls/6091

$ uname -a
Linux raspberry 6.6.23-v8-16k+ #1 SMP PREEMPT Thu Apr  4 17:36:31 UTC 2024 aarch64 GNU/Linux

Installed the driver from the 'v6.6' branch normally. Now arecord -l is empty.

$ dmesg
...
[    3.673836] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /axi/pcie@120000/rp1/i2c@74000/status
[    3.847715] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /axi/pcie@120000/rp1/i2s@a0000/#sound-dai-cells
[    3.847730] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /axi/pcie@120000/rp1/i2s@a0000/status
[    3.847759] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /axi/pcie@120000/rp1/i2c@74000/status
[    3.847775] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /soc/sound/compatible
[    3.847779] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /soc/sound/seeed-voice-card,name
[    3.847782] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /soc/sound/seeed-voice-card,channels-playback-override
[    3.847786] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /soc/sound/seeed-voice-card,channels-capture-override
[    3.847790] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /soc/sound/#address-cells
[    3.847797] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /soc/sound/#size-cells
[    3.847800] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /soc/sound/status
[    3.849122] i2c i2c-1: Failed to register i2c client ac101 at 0x1a (-16)
[    3.849127] i2c i2c-1: of_i2c: Failure registering /axi/pcie@120000/rp1/i2c@74000/ac101@1a
[    3.849134] i2c i2c-1: failed to create client for '/axi/pcie@120000/rp1/i2c@74000/ac101@1a'
[    3.849139] OF: changeset notifier error @/axi/pcie@120000/rp1/i2c@74000/ac101@1a
[    3.849220] OF: overlay: overlay apply changeset entry notify error -16
...
$ i2cdetect -y -r 1
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:                         -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- 1a -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- 35 -- -- -- -- -- 3b 3c -- -- --
40: -- -- 42 -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --

Any ideas?

Ubuntu 23.10 RPI5 seeed-2mic-voicecard

Hi All,

I installed the branch 6.6 on Ubuntu 23.10 on a RPI 5. I ran ubuntu prerequisites script then ran the install script. Everything build and installed properly, seems so. Reboot, module got loaded but "aplay -l" dosen't list the card.

I disabled the seeed-voicecard.service, rebooted and ran seeed-voicecard manually, here is the result;

  • export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin:/opt/vc/bin
  • PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin:/opt/vc/bin
  • OVERLAYS=/boot/overlays
  • '[' -d /boot/firmware/overlays ']'
  • OVERLAYS=/boot/firmware/overlays
  • dtparam -d /boot/firmware/overlays i2c_arm=on
  • modprobe i2c-dev
  • dtparam -d /boot/firmware/overlays spi=on
  • _VER_RUN=
  • CONFIG=/boot/config.txt
  • '[' -f /boot/firmware/usercfg.txt ']'
    ++ i2cdetect -y 1 0x1a 0x1a
    ++ egrep '(1a|UU)'
    ++ awk '{print $2}'
  • is_1a=1a
    ++ i2cdetect -y 1 0x35 0x35
    ++ awk '{print $2}'
    ++ egrep '(35|UU)'
  • is_35=
    ++ i2cdetect -y 1 0x3b 0x3b
    ++ egrep '(3b|UU)'
    ++ awk '{print $2}'
  • is_3b=
  • RPI_HATS='seeed-2mic-voicecard seeed-4mic-voicecard seeed-8mic-voicecard'
  • overlay=
  • '[' x1a '!=' x ']'
  • '[' x == x ']'
  • echo 'install 2mic'
    install 2mic
  • overlay=seeed-2mic-voicecard
  • asound_conf=/etc/voicecard/asound_2mic.conf
  • asound_state=/etc/voicecard/wm8960_asound.state
  • '[' x '!=' x ']'
  • '[' x '!=' x ']'
  • '[' seeed-2mic-voicecard ']'
  • echo Install seeed-2mic-voicecard ...
    Install seeed-2mic-voicecard ...
  • rm /etc/asound.conf
  • rm /var/lib/alsa/asound.state
    ++ uname -r
  • kernel_ver=6.5.0-1010-raspi
  • [[ 6.5.0-1010-raspi =~ ^4.19.*$ ]]
  • [[ 6.5.0-1010-raspi =~ ^5.*$ ]]
  • dtoverlay -d /boot/firmware/overlays seeed-2mic-voicecard
  • echo 'create seeed-2mic-voicecard asound configure file'
    create seeed-2mic-voicecard asound configure file
  • ln -s /etc/voicecard/asound_2mic.conf /etc/asound.conf
  • echo 'create seeed-2mic-voicecard asound status file'
    create seeed-2mic-voicecard asound status file
  • ln -s /etc/voicecard/wm8960_asound.state /var/lib/alsa/asound.state
  • alsactl restore
    No state is present for card ATR4697USB
    Found hardware: "USB-Audio" "USB Mixer" "USB0909:0050" "" ""
    Hardware is initialized using a generic method
    No state is present for card ATR4697USB
  • aplay -l
  • grep -q 'bcm2835 ALSA'

No errors, it just doesn't find the Respeaker 2-MIC.

What do you think I could look at?

Thanks

about kernel : kernel 6.5.0-1005-raspi cannot be found

Error! Your kernel headers for kernel 6.5.0-1005-raspi cannot be found at /lib/modules/6.5.0-1005-raspi/build or /lib/modules/6.5.0-1005-raspi/source.

USE:
Linux ubuntu 6.5.0-1005-raspi #7-Ubuntu SMP PREEMPT_DYNAMIC Sun Oct 8 08:06:18 UTC 2023 aarch64 aarch64 aarch64 GNU/Linux
v6.1 and v6.5 do not work

4-Mic Array not recognized on latest Bookworm / Bullseye installs (Rpi4, kernel 6.1)

Hi there!

First of all: Thanks for putting in the work and keeping our hardware alive!

I am having trouble getting the 4-Mic Array working on recent version of raspberry pi OS with kernel version 6.1.0 on a Raspberry Pi 4.

I have tried the available Bookworm and Bullseye versions, both 32bit and 64bit LITE versions, all with the same result:

  • Drivers installation proceeds seemingly correct (using the 6.1 branch)
  • Both my 2-Mic Arrays are recognized correctly and work as expected
  • The 4-Mic Array is not recognized (arecord -l is empty)
  • SPI communication to the APA102 LEDs on the 4-Mic array works as expected

I suspected a faulty hardware, but the 4-Mic Array works correctly using your provided buster image with drivers pre-installed.

I'm sure I'm missing something here. Do you have any pointers to what's causing the trouble?
I'd like to give more detailed info to help troubleshooting. Please, let me know what additional output/ information might help.

Kernel Panic trying to test with arecord

I am using the Seeed Respeaker 4 mic hat: https://files.seeedstudio.com/wiki/ReSpeaker-4-Mic-Array-for-Raspberry-Pi/img/connect2.jpg

The SD card died in my Pi3b voice assistant so I thought I'd try and upgrade it to a Pi4 I was using elsewhere.

Flash latest official Pi Lite version to SD card:

Linux vision 6.1.0-rpi7-rpi-v8 #1 SMP PREEMPT Debian 1:6.1.63-1+rpt1 (2023-11-24) aarch64 GNU/Linux

git clone https://github.com/HinTak/seeed-voicecard.git

The default branch is v6.1 so good to go there.

sudo ./install.sh and reboot

After reboot:
arecord -L

hw:CARD=seeed4micvoicec,DEV=0
    seeed-4mic-voicecard, bcm2835-i2s-ac10x-codec0 ac10x-codec0-0
    Direct hardware device without any conversions

Try and record as per the instructions on the wiki:

arecord -Dac108 -f S32_LE -r 16000 -c 4 hello.wav

Kernel Panic when pressing Ctrl+C to stop recording
20231228_150718
Seems to be 100% repro rate

I tried using the linked (super old) version of Buster with the drivers pre-installed (https://files.seeedstudio.com/linux/Raspberry%20Pi%204%20reSpeaker/2021-05-07-raspios-buster-armhf-lite-respeaker.img.xz)

That works correctly and I can record, sox to stereo and playback via headphones as expected, so it's not a hardware issue with the hat.

I tried using 32 bit instead of 64 bit, bit that doesn't seem to install correctly,
cannot get card index for seeed4micvoicec when trying to record.
I also tried 64 bit full desktop RPi image in case somehow that was using a different kernel, but no luck there.

It seems lots of people are working OK with 6.1 kernels from various forums around the place, so I am really not sure what is going wrong in my case.
(I did also try the hat on the PI3b with latest Pi OS and that also failed, so it's not specific to the 4)

Any help would be greatly appreciated (via donation!)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.