Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Confusing scripts and hardcoded device ids #132

Open
StuartIanNaylor opened this issue Mar 24, 2020 · 3 comments
Open

Confusing scripts and hardcoded device ids #132

StuartIanNaylor opened this issue Mar 24, 2020 · 3 comments

Comments

@StuartIanNaylor
Copy link

Got a feeling for mycroft noobs these cause raspbian confusion

{
   "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/"
}

I myself spent some time hammering with Alsa wondering why is this not working to find hardcoded conf entries.
Also

#!/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

Purely a duplication of raspi-config does and alsactl store but again by being a late boot order script it confuses those who are used to raspi methods and the docs they are likely to read.

Shouldn't need hidden hardcoded id's so just remove from script and delete audio-setup.sh as raspi-config, docs and help will often give contary methods, so they just confuse.

@fermulator
Copy link

I found this after being recommended to fork part of MycroftAI/mycroft-core#2622 into this enclosure-picroft portion of the project.

Explicitly, I would recommend similar as OP original post. See (2) from proposals I listed out there. I assume that it is still necessary to list out the play_* configurations in /etc/mycroft/mycroft.conf? -- we should just remove the hard coded device ID (at minimum).

OP has suggested to remove entirely (though I'm not sure if that is possible?) @forslund hinted that maybe this was added as a workaround and is now causing issues w/ default configuration/setups....

@forslund
Copy link
Collaborator

forslund commented Jul 5, 2020

IMHO those play_* lines should be removed from the config entirely, the issue they worked around isn't present in buster as far as I can tell...

@fermulator
Copy link

fermulator commented Jul 8, 2020

There was some discussion in mattermost : https://chat.mycroft.ai/community/pl/k48nbo3dztbumewh4kwzz7ocgy
, confirming that we should be able to remove the hard coded playback commands (which were workarounds) from the system config; as the defaults DO live in the core: https://github.com/MycroftAI/mycroft-core/blob/dev/mycroft/configuration/mycroft.conf#L53

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants