Mycroft Community Forum

Basic Install & Initial Test = Fail

I have a RPi 3 B+ with the Respeaker 2-mic and basic Logitech speakers plugged into the audio jack and USB (for power). I have Raspbian Buster Lite installed.

Followed the standard install of the Respeaker device. It seems to work. aplay -l lists the device as noted on the install guide / page.

github .com /respeaker/seeed-voicecard

If I run the speaker-test command, I hear output.

Onto Mycroft. I followed the guide at:

github.com/ MycroftAI/mycroft-core

down to the section / command:

./start-mycroft.sh debug

In the terminal (SSH) session, I see loads of stuff. I think its a default updater and installing default skills(?) but I’m not sure.

I issued the “Hey Mycroft, pair my device” command. At some point I saw a 6-digit code and this has worked registering on the home.mycroft.ai website.

However, all commands do nothing. I have not heard 1 sound out of Mycroft.

I don’t know if the mic or the speakers are working.

I saw this thread but seems quite advanced from my initial / current position:

Can I ask for some assistance please?

I would try playback and record first.

arecord --help
aplay --help

Or simple

arecord alsa-rec.wav

Then playback

aplay alsa-rec.wav

Thats a basic alsa test and then pulseaudio

parecord --help
paplay --help

parecord pa-rec.wav

paplay-rec.wav

Test your linux audio first

aplay -L will list devices
pacmd list-cards same for pulseaudio

Try that and post your findings

Thanks.

the arecord and aplay commands work fine - my dulcet tones recorded and played back.

the PulseAudio command do not, with error:

sudo parecord myaudio2.wav
Connection failure: Connection refused
pa_context_connect() failed: Connection refused
pi@picroft:~/mycroft-core $ paplay /usr/share/sounds/alsa/Front_Left.wav
Connection failure: Connection refused
pa_context_connect() failed: Connection refused

Output of aplay -L:

pi@picroft:~/mycroft-core $ aplay -L
null
Discard all samples (playback) or generate zero samples (capture)
jack
JACK Audio Connection Kit
pulse
PulseAudio Sound Server
default
playback
capture
dmixed
array
sysdefault:CARD=ALSA
bcm2835 ALSA, bcm2835 ALSA
Default Audio Device
dmix:CARD=ALSA,DEV=0
bcm2835 ALSA, bcm2835 ALSA
Direct sample mixing device
dmix:CARD=ALSA,DEV=1
bcm2835 ALSA, bcm2835 IEC958/HDMI
Direct sample mixing device
dmix:CARD=ALSA,DEV=2
bcm2835 ALSA, bcm2835 IEC958/HDMI1
Direct sample mixing device
dsnoop:CARD=ALSA,DEV=0
bcm2835 ALSA, bcm2835 ALSA
Direct sample snooping device
dsnoop:CARD=ALSA,DEV=1
bcm2835 ALSA, bcm2835 IEC958/HDMI
Direct sample snooping device
dsnoop:CARD=ALSA,DEV=2
bcm2835 ALSA, bcm2835 IEC958/HDMI1
Direct sample snooping device
hw:CARD=ALSA,DEV=0
bcm2835 ALSA, bcm2835 ALSA
Direct hardware device without any conversions
hw:CARD=ALSA,DEV=1
bcm2835 ALSA, bcm2835 IEC958/HDMI
Direct hardware device without any conversions
hw:CARD=ALSA,DEV=2
bcm2835 ALSA, bcm2835 IEC958/HDMI1
Direct hardware device without any conversions
plughw:CARD=ALSA,DEV=0
bcm2835 ALSA, bcm2835 ALSA
Hardware device with all software conversions
plughw:CARD=ALSA,DEV=1
bcm2835 ALSA, bcm2835 IEC958/HDMI
Hardware device with all software conversions
plughw:CARD=ALSA,DEV=2
bcm2835 ALSA, bcm2835 IEC958/HDMI1
Hardware device with all software conversions
usbstream:CARD=ALSA
bcm2835 ALSA
USB Stream Output
sysdefault:CARD=seeed2micvoicec
seeed-2mic-voicecard,
Default Audio Device
dmix:CARD=seeed2micvoicec,DEV=0
seeed-2mic-voicecard,
Direct sample mixing device
dsnoop:CARD=seeed2micvoicec,DEV=0
seeed-2mic-voicecard,
Direct sample snooping device
hw:CARD=seeed2micvoicec,DEV=0
seeed-2mic-voicecard,
Direct hardware device without any conversions
plughw:CARD=seeed2micvoicec,DEV=0
seeed-2mic-voicecard,
Hardware device with all software conversions
usbstream:CARD=seeed2micvoicec
seeed-2mic-voicecard
USB Stream Output

paplay has options

-d | --device =SINK

Specify the symbolic name of the sink to play this file on.

so try paplay -d or paplay --device with the correct device name from paplay -L

Why Mycroft has various audio conf files I will let you ask someone else.
You can set it in several place but which is ‘correct’ or why multiple places you can set conf is curious.

With the Respeaker Pi 2 Mic did you setup the Echo Cancellation list on the first wiki page
Acoustic Echo Cancellation AEC project

You can also do it via pulseaudio by adding at the end

    ### Enable Echo/Noise-Cancellation
    load-module module-echo-cancel use_master_format=1 aec_method=webrtc aec_args="analog_gain_control=0\ digital_gain_control=1\ agc_start_volume=85\ beamforming=1\ mic_geometry=-0.03,0,0,0.03,0,0"  source_name=echoCancel_source sink_name=echoCancel_sink

    set-default-source echoCancel_source
    set-default-sink echoCancel_sink

To /etc/pulse/default.pa just sudo nano /etc/pulse/default.pa
Its X,Y,Z in meters from center of device.
Unfortunately that is getting dropped from pulseaudio as upstream in webrtc it already has.

So use the Respeaker guide as it is webrtc but the repo’s hopefully will remain.

Someone should be sending @gez-mycroft pressies of

  • 2 Mic Array for Pi
  • 4 Mic Array for Pi
  • Linear 4 Mic Array for Pi
  • USB 4 Mic Array

As a Howto Mic setup for Dummies, step by step guide would be of much use to many.
As its pretty simple but also quite confusing.

But if you check the 4 Mic Array for Pi / Linear 4 Mic Array for Pi info you can use the other great libs they provide but change the channels to 2 where it says.

A quick search suggested that PulseAudio wasn’t running, and to issue command pulseaudio --start.

paplay command now runs without the error, but there is no sound any more.

Trying to re-run aplay command, which also no longer plays a sound.

Rebooted to see if it would restore previous state, but it doesn’t, and seems Pulseaudio runs automatically from boot now…

pacmd list-cards returns (when pulseaudio is running):

pi@picroft:~/mycroft-core $ pacmd list-cards
2 card(s) available.
index: 0
name: <alsa_card.platform-soc_audio>
driver: <module-alsa-card.c>
owner module: 6
properties:
alsa.card = “0”
alsa.card_name = “bcm2835 ALSA”
alsa.long_card_name = “bcm2835 ALSA”
alsa.driver_name = “snd_bcm2835”
device.bus_path = “platform-soc:audio”
sysfs.path = “/devices/platform/soc/soc:audio/sound/card0”
device.form_factor = “internal”
device.string = “0”
device.description = “Built-in Audio”
module-udev-detect.discovered = “1”
device.icon_name = “audio-card”
profiles:
output:analog-mono: Analog Mono Output (priority 700, available: unknown)
off: Off (priority 0, available: unknown)
active profile: output:analog-mono
sinks:
alsa_output.platform-soc_audio.analog-mono/#0: Built-in Audio Analog Mono
sources:
alsa_output.platform-soc_audio.analog-mono.monitor/#0: Monitor of Built-in Audio Analog Mono
ports:
analog-output: Analog Output (priority 9900, latency offset 0 usec, available: unknown)
properties:

index: 1

name: <alsa_card.platform-soc_sound>
driver: <module-alsa-card.c>
owner module: 7
properties:
alsa.card = “1”
alsa.card_name = “seeed-2mic-voicecard”
alsa.long_card_name = “seeed-2mic-voicecard”
alsa.driver_name = “snd_soc_simple_card”
device.bus_path = “platform-soc:sound”
sysfs.path = “/devices/platform/soc/soc:sound/sound/card1”
device.form_factor = “internal”
device.string = “1”
device.description = “Built-in Audio”
module-udev-detect.discovered = “1”
device.icon_name = “audio-card”
profiles:
input:stereo-fallback: Stereo Input (priority 51, available: unknown)
input:multichannel-input: Multichannel Input (priority 1, available: unknown)
output:stereo-fallback: Stereo Output (priority 5100, available: unknown)
output:stereo-fallback+input:stereo-fallback: Stereo Output + Stereo Input (priority 5151, available: unknown)
output:stereo-fallback+input:multichannel-input: Stereo Output + Multichannel Input (priority 5101, available: unknown)
output:multichannel-output: Multichannel Output (priority 100, available: unknown)
output:multichannel-output+input:stereo-fallback: Multichannel Output + Stereo Input (priority 151, available: unknown)
output:multichannel-output+input:multichannel-input: Multichannel Duplex (priority 101, available: unknown)
off: Off (priority 0, available: unknown)
active profile: output:stereo-fallback+input:stereo-fallback
sinks:
alsa_output.platform-soc_sound.stereo-fallback/#1: Built-in Audio Stereo
sources:
alsa_output.platform-soc_sound.stereo-fallback.monitor/#1: Monitor of Built-in Audio Stereo
alsa_input.platform-soc_sound.stereo-fallback/#2: Built-in Audio Stereo
ports:
analog-input: Analog Input (priority 10000, latency offset 0 usec, available: unknown)
properties:

  multichannel-input: Multichannel Input (priority 0, latency offset 0 usec, available: unknown)
  	properties:

  analog-output-speaker: Speakers (priority 10000, latency offset 0 usec, available: unknown)
  	properties:
  		device.icon_name = "audio-speakers"
  analog-output-headphones: Headphones (priority 9000, latency offset 0 usec, available: unknown)
  	properties:
  		device.icon_name = "audio-headphones"
  multichannel-output: Multichannel Output (priority 0, latency offset 0 usec, available: unknown)
  	properties:

From this output, what should the value for the paplay -d switch be?

Update…

The Respeaker has it’s own 3.5mm audio jack, which the speakers were plugged into. This had worked on initial install / run.

I switched the speakers to the Pi’s own audio jack and both aplay filename.wav and paplay filename.wav produces output, and the mic’s are still recording too.

(note, for paplay, this didn’t require the “-d” switch)

Pulseaudio should start or do you have to enable it? My memory but hey.
systemctl --user enable pulseaudio.service
It will now start on each boot.

https://www.alsa-project.org/wiki/Asoundrc
But basically create a $HOME/.asoundrc conf file and we will shift to the better DAC presuming so as the Pi is adequate but not the best.

Which because its the same for sink/source (speaker/mic) then this will prob do it.

pcm.!default {
        type hw
        card 1
}

ctl.!default {
        type hw           
        card 1
}

Swap your jack and give it a reboot and check service has started and sound is now from the respeaker.
There is no source on card 0 (armsoc) hence why it picked up the mic on the respeaker.
I am thinking if ALSA is set then with current settings pulseaudio will follow suit.

Also if you tack this to the end of /etc/pulse/default.pa you will also have AEC and Autogain with a singular mic stream for mycroft processing.

    ### Enable Echo/Noise-Cancellation
    load-module module-echo-cancel use_master_format=1 aec_method=webrtc aec_args="analog_gain_control=0 digital_gain_control=1 agc_start_volume=85 beamforming=1 mic_geometry=-0.03,0,0,0.03,0,0"  source_name=echoCancel_source sink_name=echoCancel_sink

    set-default-source echoCancel_source
    set-default-sink echoCancel_sink

PS I always forget if its the conf or cli that needs \ delimiters after for each parameter that has a following one.
If the above doesn’t seem to do anything pacmd list will give a fairly exhaustive list and you should have echoCancel_source/echoCancel_sink in there
pacmd list-sinks for outputs pacmd list-sources for inputs

If not I have got it the wrong way round and its

load-module module-echo-cancel use_master_format=1 aec_method=webrtc aec_args="analog_gain_control=0\ digital_gain_control=1\ agc_start_volume=85\ beamforming=1\ mic_geometry=-0.03,0,0,0.03,0,0"  source_name=echoCancel_source sink_name=echoCancel_sink

Its one of the 2 :slight_smile:
The 0.03 measurement should be what ever the distance is from the center of the respeaker card to mic in meter.
So its 2 mics 6cm apart 3cm from center in the above hence +/- values
That codec doesn’t look that bad.
https://www.cirrus.com/products/wm8960/

https://mycroft-ai.gitbook.io/docs/using-mycroft-ai/troubleshooting/audio-troubleshooting

Thanks again @StuartIanNaylor

But the .asoundrc file isn’t working after a reboot. Sounds only play through the onboard audio jack. I even queried it with:

aplay -D hw:1,0 filename.wav

To force it through the Respeaker, but it didn’t work (presuming my logic / syntax is correct).

And also for testing:
aplay -D default filename.wav

Which also came through the onboard audio jack.

Oh sod it :slight_smile: We will just turn soc audio off.
/boot/config.txt
dtparam=audio=off

My bad I guess as its card 1 for output and card 0 for input.

Should of prob had playback and capture defined so it gets the card difference as even though same card the index is different due to the internal sound card but no internal input.

    playback.pcm "hw:0,0"
    capture.pcm "hw:1,0"

Delete that .rcsoundrc turn off built in audio and you should be good to go, but prob should of been above.

Problem is the Myford setup scripts for me make things more confusing as it should be fairly easy to use standard amixer tools to set the sound setup.
There is /home/pi/audio_setup.sh that contains

#!/bin/bash
# Use this script to execute audio setup actions
sudo amixer cset numid=3 "1" > /dev/null 2>&1
amixer set PCM 79% > /dev/null 2>&1
amixer set Master 79% > /dev/null 2>&1

So even if I did get a asoundrc right its prob going to be overwritten on login, but wow make something confusing as which runs first bashrc or asoundrc?
Why does that exist as that is what asoundrc is for or standard tools like alsactl store?

Then you have /home/pi/.setup_choices

{
  "audio": "analog_audio",
  "mic": "ps_eye"
}

Then we have /etc/mycroft/mycroft.conf

{
   "play_wav_cmdline": "aplay -Dhw:0,0 %1",
   "play_mp3_cmdline": "mpg123 -a hw:0,0 %1",
   "enclosure": {
      "platform": "picroft"
   },
   "tts": {
      "mimic": {
         "path": "/home/pi/mycroft-core/mimic/bin/mimic"
      }
   },
   "ipc_path": "/ramdisk/mycroft/ipc/"
}

then we also have the helper scripts
mycroft-config set listener.device_name

To what and why is a complete confusion to me as you can set once with amixer and then sudo alsactl store
Which will save current settings to /var/lib/alsa/asound.state
Its sudo /etc/init.d/alsa-utils reset to reset

So even though could do the following

amixer show basic info
amixer controls show the basic controls
amixer cget numid=3 get info for control 3

# While the Raspberry Pi is a standard board, these have been known to vary by
# system; you can always use `aplay -L` to check
# sudo amixer cset numid=3 "0"  # audio out to the USB soundcard
# sudo amixer cset numid=3 "1"  # audio out the analog speaker/headphone jack
# sudo amixer cset numid=3 "2"  # audio out the HDMI port (e.g. TV speakers)

I have never used sound headless before on linux so alsa and pulseaudio is all new to me as it was just there on the desktop and worked.
The above bemused me as thought that would just set the master volume but seems if in quotes its sets the hardware ID, but really not sure why so many different places and settings and why not standard Alsa utils.
So why not sudo alsactl store and default alsa controls and

sudo /etc/init.d/alsa-utils reset

To reset back?
Scripts that don’t add functionality but are purely a different method to standard function are not a good idea, but hey.

Prob easiest way if just to disable builtin audio in this case and delete my bad attempt at a asoundrc.
As its still likely for what ever reason there is a conf galore of options of extra scripts to what asla-utils does natively.
I really don’t get why and will leave you to decide but now you should be a Mycroft audio setup expert and one of those configs should work or like me you may get so confused and totally make a hash of things.
Just delete what you did and reset and start from scratch again but why things are in this way to supposedly make things easier is just a bemusing reality to me.
Things often are, we have Trump and things called Brexit and obviously I am just not in the loop.

Not any expert, though I am following along… as far as I can tell from /usr/share/alsa/alsa.conf, at the top it has:

@hooks [
  {
    func load
    files [
  	   "/etc/alsa/conf.d"
     	   "/etc/asound.conf"
  	   "~/.asoundrc"
  ]
  errors false
  }
 ]

So I am assuming ~/.asoundrc should be applied LAST?

I had expected the standard installation to include the onboard device as well as detecting an additional sound card or the ability to add it in(?). I can disable the onboard sound card but it doesn’t seem “right” to me.

Following your logic, I expected ALSA to recognise this “hw” card as 1, from the aplay -l command:

pi@picroft:~ $ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: ALSA [bcm2835 ALSA], device 0: bcm2835 ALSA [bcm2835 ALSA]
Subdevices: 7/7
Subdevice #0: subdevice #0
Subdevice #1: subdevice #1
Subdevice #2: subdevice #2
Subdevice #3: subdevice #3
Subdevice #4: subdevice #4
Subdevice #5: subdevice #5
Subdevice #6: subdevice #6
card 0: ALSA [bcm2835 ALSA], device 1: bcm2835 IEC958/HDMI [bcm2835 IEC958/HDMI]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: ALSA [bcm2835 ALSA], device 2: bcm2835 IEC958/HDMI1 [bcm2835 IEC958/HDMI1]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: seeed2micvoicec [seeed-2mic-voicecard], device 0: bcm2835-i2s-wm8960-hifi wm8960-hifi-0 []
Subdevices: 1/1
Subdevice #0: subdevice #0

And therefore, my “hw:1,0” format. Should this have been “hw:0,1” ?

The system-wide config seems to have defined the Seeed device as “dmixed” and “array” - could I use these instead?

pi@picroft:~ $ cat .asoundrc
pcm.!default {
type hw
card 1
}

ctl.!default {
type hw
card 1
}

pi@picroft:~ $ cat /etc/asound.conf

The IPC key of dmix or dsnoop plugin must be unique

If 555555 or 666666 is used by other processes, use another one

use samplerate to resample as speexdsp resample is bad

defaults.pcm.rate_converter “samplerate”

pcm.!default {
type asym
playback.pcm “playback”
capture.pcm “capture”
}

pcm.playback {
type plug
slave.pcm “dmixed”
}

pcm.capture {
type plug
slave.pcm “array”
}

pcm.dmixed {
type dmix
slave.pcm “hw:seeed2micvoicec”
ipc_key 555555
}

pcm.array {
type dsnoop
slave {
pcm “hw:seeed2micvoicec”
channels 2
}
ipc_key 666666
}

I have no idea if .asoundrc should be applied last as Myford calls an amixer cset in /home/pi/audio_setup.sh that script runs on login so anything you do will be overwritten.
Its not Alsa config its Mycroft config you need to set and why it exists as all you need to do is use the Alsa_utils in that script once and then run sudo alsactl store to save the state of the settings you have just made.

But also /etc/mycroft/mycroft.conf contains devices specified by hardware index so messing with alsa is going to do nothing.

{
   "play_wav_cmdline": "aplay -Dhw:0,0 %1",
   "play_mp3_cmdline": "mpg123 -a hw:0,0 %1",
   "enclosure": {
      "platform": "picroft"
   },
   "tts": {
      "mimic": {
         "path": "/home/pi/mycroft-core/mimic/bin/mimic"
      }
   },
   "ipc_path": "/ramdisk/mycroft/ipc/"
}
#!/bin/bash
# Use this script to execute audio setup actions
sudo amixer cset numid=3 "1" > /dev/null 2>&1
amixer set PCM 79% > /dev/null 2>&1
amixer set Master 79% > /dev/null 2>&1

I have absolutely no idea which runs first and I was only doing a simple copy and paste !default asoundrc.
Do not bother with .asoundrc and definately stay away /usr/share/alsa/alsa.conf why are you going there?

Alsa is quite simple to set the current control device you set it to “1” as in.
sudo amixer cset numid=3 "1"
To set any volume you reference the volume name and set as a % as in amixer set Master 79%
Then you run sudo alsactl store
Thats it done you just reboot to see if that state is correct as its the simplest way.
Its very similar with system services as do you start hacking the conf files of systemd or do you just systemctl enable service?

The problem isn’t with Alsa its the Myford scripts that have been chosen as they run on logon and will change the initial conf or any saved state.
You have to use and modify /home/pi/audio_setup.sh because it exists.
Also you have to modify /etc/mycroft/mycroft.conf because the hardware indexs exist.

You are a relative expert about Alsa as you already know far more than you should.

pi@picroft:~ $ amixer
Simple mixer control 'Master',0
  Capabilities: pvolume pvolume-joined pswitch pswitch-joined
  Playback channels: Mono
  Limits: Playback 0 - 65536
  Mono: Playback 51774 [79%] [on]
Simple mixer control 'Capture',0
  Capabilities: cvolume cswitch cswitch-joined
  Capture channels: Front Left - Front Right - Rear Left - Rear Right
  Limits: Capture 0 - 65536
  Front Left: Capture 65536 [100%] [on]
  Front Right: Capture 65536 [100%] [on]
  Rear Left: Capture 65536 [100%] [on]
  Rear Right: Capture 65536 [100%] [on]
amixer controls
numid=4,iface=MIXER,name='Master Playback Switch'
numid=3,iface=MIXER,name='Master Playback Volume'
numid=2,iface=MIXER,name='Capture Switch'
numid=1,iface=MIXER,name='Capture Volume'

So from that I should be able to do

sudo amixer cset numid=4 "1"
sudo amixer cset numid=2 "1"
sudo alsactl store
sudo reboot

Also turn off any you don’t want.

Its the myford scripts that run on boot on logon which happens late in boot order that will confuse and change settings.

You could create a ${HOME}/.asoundrc but likely it will not be used unless you edit the Mycroft scripts & conf.
As an example

pcm.array {
 type hw
 card 0
}

pcm.array_gain {
 type softvol
   slave {
   pcm "array"
   }
 control {
   name "Mic Gain"
   count 2
   card 0
   }
 min_dB -40.0
 max_dB 10.0
 resolution 80
}

pcm.cap {
 type plug
 slave {
   pcm "array_gain"
   channels 4
   }
 route_policy sum
}

Which will just sum that array and create a cap pcm stream.

Mycroft uses pulseaudio which is just a server daemon ontop of Alsa which has the webrtc Echo Cancellation routines and also a beamforming routine that will sum the channels and correct the latency of those channels so it should be a cleaner sum.

So leave .asoundrc as a multi channel array (no config just default) and feed into pulseaudio.
Adopt what I wrote in
PS3 Eye Best Settings for 2 channels
Which basically is just tacking on the end of /etc/pulse/default.pa

    ### Enable Echo/Noise-Cancellation
    load-module module-echo-cancel use_master_format=1 aec_method=webrtc aec_args="analog_gain_control=0\ digital_gain_control=1\ agc_start_volume=85\ beamforming=1\ mic_geometry=-0.03,0,0,0.03,0,0\ target_direction=1.571,0,0"  source_name=echoCancel_source sink_name=echoCancel_sink

    set-default-source echoCancel_source
    set-default-sink echoCancel_sink

The Auto gain control is preference as it can make recognition worse or better due to scenario.
“1” = on & “0” = Off.
I never played with these

  • high_pass_filter=1 May help as much is outside voice spectrum
  • noise_suppression=1 - Noise suppression. Noise suppression can clean but seems to do little to improve recognition
  • voice_detection=1 - VAD - Voice activity detection which wasn’t sure its a RMS value of average voice spectrum but never worked out if it mutes if not of a level.

The target direction has no update but the above should create a beam perpendicular to your 2 mic array.

The beamforming sadly has been dropped from webrtc as its becoming part of devices rather than needing software so on the next release of pulseaudio it works for now.

Otherwise take a look at the respeaker wiki for the 4 mic array as the EC & DOA could equally be used for 2 mic as 4 mic, but still waiting for my 4 mic and havent really played with them yet.

You are quite an Alsa expert already as said it pretty simple stuff the confusion is why and what Mycroft sets up in scripts and conf.
Generally its a WTF is that Mycroft setup stuff because I am confused at rationale and implementation, to something that has simple default setup tools built in aka alsa_utils.

amixer --help
alsactl --help

May give your more info but its likely you will find its the Mycroft script and conf that are doing the setting and making this far more confusing than it should.

There is also /home/pi/.setup_choices

{
  "audio": "analog_audio",
  "mic": "ps_eye"
}

Which I am totally clueless about.

# While the Raspberry Pi is a standard board, these have been known to vary by
# system; you can always use `aplay -L` to check
# sudo amixer cset numid=3 "0"  # audio out to the USB soundcard
# sudo amixer cset numid=3 "1"  # audio out the analog speaker/headphone jack
# sudo amixer cset numid=3 "2"  # audio out the HDMI port (e.g. TV speakers)

Was just copied from a Mycroft script and my advice is to ignore as it make literally no sense.
amixer controls will prove that as controls are switches, volumes and more, not card devices.

pi@picroft:~ $ amixer controls
numid=4,iface=MIXER,name='Master Playback Switch'
numid=3,iface=MIXER,name='Master Playback Volume'
numid=2,iface=MIXER,name='Capture Switch'
numid=1,iface=MIXER,name='Capture Volume'

Hence why I am guestimating editing /boot/config.txt

dtparam=audio=off

sudo reboot

Is likely a fix as fiddling with alsa will likely do nothing due to the strange audio setup of Mycroft.
Dunno as its the Mycroft config and rationale that confuses me but you have that info and you can test as don’t have a 2 mic and still waiting for my 4 mic.

Thanks

It seems I broke the Pi, unplugging the HDMI cable while powered on. Now the unit will not boot, no ACT light.

Awaiting a new unit being delivered, if the company still are with covid-19 pandemic…

But then I can retry all this. Best way to learn…

Only looking at other Alsa files to get an understanding. I need to ensure the hardware is functioning properly - mic and speakers - before moving onto Mycroft stuff I think.

Yeah its easy enough but whatever you set will be overwritten by various Mycroft scripts.

So set up on vanilla use raspi-config to force 3.5mm audio or /boot/config.txt and disable onboard audio all together with dtparam=audio=off

The you have /etc/mycroft/mycroft.conf which will confuse on playback

{
   "play_wav_cmdline": "aplay -Dhw:0,0 %1",
   "play_mp3_cmdline": "mpg123 -a hw:0,0 %1",
   "enclosure": {
      "platform": "picroft"
   },
   "tts": {
      "mimic": {
         "path": "/home/pi/mycroft-core/mimic/bin/mimic"
      }
   },
   "ipc_path": "/ramdisk/mycroft/ipc/"
}

also
/home/pi/audio_setup.sh

#!/bin/bash
# Use this script to execute audio setup actions
sudo amixer cset numid=3 "1" > /dev/null 2>&1
amixer set PCM 79% > /dev/null 2>&1
amixer set Master 79% > /dev/null 2>&1

Which really you don’t need and just comment then out

#!/bin/bash
# Use this script to execute audio setup actions
#sudo amixer cset numid=3 "1" > /dev/null 2>&1
#amixer set PCM 79% > /dev/null 2>&1
#amixer set Master 79% > /dev/null 2>&1

Remove the hardware specifics from the play cli commands

{
   "play_wav_cmdline": "aplay %1",
   "play_mp3_cmdline": "mpg123 %1",
   "enclosure": {
      "platform": "picroft"
   },
   "tts": {
      "mimic": {
         "path": "/home/pi/mycroft-core/mimic/bin/mimic"
      }
   },
   "ipc_path": "/ramdisk/mycroft/ipc/"
}

Now when you play with Alsa it will not be just overwritten so it will use defaults set.
I was the same getting confused with Alsa but for some reason its hardcoded with specific hardware requirements.
Not sure why they are included or the audio setup as Mycroft itself is a specific device, whilst a limited shortlist of hardware in Picroft just seems to make things more confusing for little benefit?

But hey its fairly simple once you do the above and think it would just be better without, from the start.