Current version of the OpenAuto Pro is 5.0
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
OAP5 on RPi4B + AudioInjector Octo
#1
Hello OAP community,

I'm new to OA and I'm glad I found this software. I finally got most things in my project working on my Raspberry Pi 4B with OAP 5.0 (Downloaded 1/7/2020). This project is going into a silver VW Corrado.

[Image: ezgif.com-video-to-gifb266a6ce481aeeec.gif]
  • Raspberry Pi 4 B (2GB)
  • Official Raspberry Pi 7" Touchscreen Display
  • AudioInjector Octo sound card (Only using the 8 channel output)
  • TROND AC3-A USB Audio Adapter (3 jacks: 3.5mm TRS headphone, 3.5mm TRS microphone, 3.5mm TRRS headset)
  • TECHKEY Mini Size USB Bluetooth Dongle (Bluetooth 4.0+EDR, 0a5c:21e8 Broadcom Corp. BCM20702A0 Bluetooth 4.0) Firmware from here: https://github.com/winterheart/broadcom-bt-firmware (So, at least one Broadcom chipset works)
  • Insignia Lavalier Microphone (Model: NS-MCMIC10, 3.5mm TRRS)
  • Smarticase Smarti Pi Touch 2 Case with 35mm back cover
  • RTC for RPI  (DS1307 Chip: HYM1307Z)
  • SunFounder DS18B20 Temperature Sensor Module
Tested as working:
  • Hands-free calling
  • A2DP audio/music
  • Mirroring
  • Android Auto (as long as arm_64bit=1 is not set in config.txt) (tested with Android 5.1 and Android 7.1.1)
  • Google Maps, Waze
  • Equalizer
  • DS18B20 Temperature display
Not working
  • Volume slider and buttons (I'm aware of the default Master mixer and MixerName option in openauto_system.ini, but I haven't been able to make that work for the AudioInjector Octo. I may need to figure out how to successfully create a Softvol Master for the AudioInjector Octo sound card. Maybe pulseaudio's simultaneous output sink [module-combine/module-combine-sink] might help? If I can't make it work, I suppose I can always use the USB sound card for output instead. I hope I don't have to...)
  • Mute button
Have not tested 
  • Rear camera (I don't have one... yet).
I did have to remove the Volume plugin from the Raspbian PIXEL panel/taskbar because that kept screwing up my custom Alsa config. I'll likely be adding a temperature sensor, RTC and I'm hoping the 4A Mausberry supply actually works (I've heard less-than-great reviews, but I already ordered one so we'll see).

Anybody know why this project uses PulseAudio 10.0 and not a newer version? Where should bugs be reported?

I noticed what is probably a simple mistake (missing first S in SUBSYSTEM) in a udev rules file -- /etc/udev/rules.d/99-androidauto.rules
Code:
UBSYSTEM=="usb", ATTR{idVendor}=="*", ATTR{idProduct}=="*", MODE="0660", GROUP="plugdev"


I think /etc/dbus-1/system.d/ofono.conf may need to be adjusted to allow certain communications between pulseaudio and ofono. I haven't really looked into it though, I just noticed some noise in the logs.

Here is what is mostly working for me:

/etc/asound.conf
Code:
pcm.!default {
    type asym
    hint {
        show on
        description "Default ALSA Output+Input (AudioInjector Octo)"
    }
    playback.pcm {
        type plug
        slave.pcm "output"
    }
    capture.pcm {
        type plug
        slave.pcm "input"
    }
}

ctl.!default {
    type hw
    card 0
}

pcm.output {
    type route
    slave.pcm "hw:0"
    slave.channels 8;
    ttable {
        0.0 1
        1.1 1
        2.2 1
        3.3 1
        4.4 1
        5.5 1
        6.6 1
        7.7 1
    }
}

pcm.input {
    type hw
    card 1
}

ctl.output {
    type hw
    card 0
}

ctl.input {
        type hw
        card 1
}

/home/pi/.config/pulse/default.pa
Code:
#!/usr/bin/pulseaudio -nF
#
# This file is part of PulseAudio.
#
# PulseAudio is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# PulseAudio is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public License
# along with PulseAudio; if not, see <http://www.gnu.org/licenses/>.

# This startup script is used only if PulseAudio is started per-user
# (i.e. not in system mode)

.fail

### Automatically restore the volume of streams and devices
load-module module-device-restore
load-module module-stream-restore
load-module module-card-restore

### Automatically augment property information from .desktop files
### stored in /usr/share/application
load-module module-augment-properties

### Should be after module-*-restore but before module-*-detect
load-module module-switch-on-port-available

### Load audio drivers statically
### (it's probably better to not load these drivers manually, but instead
### use module-udev-detect -- see below -- for doing this automatically)
load-module module-alsa-sink device=dmix:0
load-module module-alsa-source device=dsnoop:1
#load-module module-oss device="/dev/dsp" sink_name=output source_name=input
#load-module module-oss-mmap device="/dev/dsp" sink_name=output source_name=input
#load-module module-null-sink
#load-module module-pipe-sink

### Automatically load driver modules depending on the hardware available
#.ifexists module-udev-detect.so
#load-module module-udev-detect tsched=0 ignore_dB=1
#.else
### Use the static hardware detection module (for systems that lack udev support)
#load-module module-detect
#.endif

### Automatically connect sink and source if JACK server is present
.ifexists module-jackdbus-detect.so
.nofail
load-module module-jackdbus-detect channels=2
.fail
.endif

### Automatically load driver modules for Bluetooth hardware
.ifexists module-bluetooth-policy.so
load-module module-bluetooth-policy
.endif

### Load several protocols
.ifexists module-esound-protocol-unix.so
load-module module-esound-protocol-unix
.endif
load-module module-native-protocol-unix

### Network access (may be configured with paprefs, so leave this commented
### here if you plan to use paprefs)
#load-module module-esound-protocol-tcp
#load-module module-native-protocol-tcp
#load-module module-zeroconf-publish

### Load the RTP receiver module (also configured via paprefs, see above)
#load-module module-rtp-recv

### Load the RTP sender module (also configured via paprefs, see above)
#load-module module-null-sink sink_name=rtp format=s16be channels=2 rate=44100 sink_properties="device.description='RTP Multicast Sink'"
#load-module module-rtp-send source=rtp.monitor

### Load additional modules from GSettings. This can be configured with the paprefs tool.
### Please keep in mind that the modules configured by paprefs might conflict with manually
### loaded modules.
.ifexists module-gsettings.so
.nofail
load-module module-gsettings
.fail
.endif

### Automatically restore the default sink/source when changed by the user
### during runtime
### NOTE: This should be loaded as early as possible so that subsequent modules
### that look up the default sink/source get the right value
load-module module-default-device-restore

### Automatically move streams to the default sink if the sink they are
### connected to dies, similar for sources
load-module module-rescue-streams

### Make sure we always have a sink around, even if it is a null sink.
#load-module module-always-sink

### Honour intended role device property
load-module module-intended-roles

### Automatically suspend sinks/sources that become idle for too long
#load-module module-suspend-on-idle

### If autoexit on idle is enabled we want to make sure we only quit
### when no local session needs us anymore.
.ifexists module-console-kit.so
load-module module-console-kit
.endif
.ifexists module-systemd-login.so
load-module module-systemd-login
.endif

### Enable positioned event sounds
load-module module-position-event-sounds

### Cork music/video streams when a phone stream is active
#load-module module-role-cork

### Modules to allow autoloading of filters (such as echo cancellation)
### on demand. module-filter-heuristics tries to determine what filters
### make sense, and module-filter-apply does the heavy-lifting of

load-module module-filter-heuristics
load-module module-filter-apply

### Make some devices default
#set-default-sink output
#set-default-source input
#set-card-profile 0 output:multichannel-output+input:multichannel-input
#set-default-sink alsa_output.platform-soc_sound.multichannel-output

/etc/systemd/system/bluetooth.service
Code:
[Unit]
Description=Bluetooth service
Documentation=man:bluetoothd(8)
ConditionPathIsDirectory=/sys/class/bluetooth

[Service]
Type=dbus
BusName=org.bluez
ExecStart=/usr/lib/bluetooth/bluetoothd --noplugin=sap
NotifyAccess=main
#WatchdogSec=10
#Restart=on-failure
CapabilityBoundingSet=CAP_NET_ADMIN CAP_NET_BIND_SERVICE
LimitNPROC=1
ProtectHome=true
ProtectSystem=full

[Install]
WantedBy=bluetooth.target
Alias=dbus-org.bluez.service

/boot/config.txt
Code:
# For more options and information see
# http://rpf.io/configtxt
# Some settings may impact device functionality. See link above for details

# uncomment if you get no picture on HDMI for a default "safe" mode
#hdmi_safe=1

# uncomment this if your display has a black border of unused pixels visible
# and your display can output without overscan
#disable_overscan=1

# uncomment the following to adjust overscan. Use positive numbers if console
# goes off screen, and negative if there is too much border
#overscan_left=16
#overscan_right=16
#overscan_top=16
#overscan_bottom=16

# uncomment to force a console size. By default it will be display's size minus
# overscan.
#framebuffer_width=1280
#framebuffer_height=720

# uncomment if hdmi display is not detected and composite is being output
#hdmi_force_hotplug=1

# uncomment to force a specific HDMI mode (this will force VGA)
#hdmi_group=1
#hdmi_mode=1

# uncomment to force a HDMI mode rather than DVI. This can make audio work in
# DMT (computer monitor) modes
#hdmi_drive=2

# uncomment to increase signal to HDMI, if you have interference, blanking, or
# no display
#config_hdmi_boost=4

# uncomment for composite PAL
#sdtv_mode=2

#uncomment to overclock the arm. 700 MHz is the default.
#arm_freq=800

# Uncomment some or all of these to enable the optional hardware interfaces
dtparam=i2c_arm=on
dtparam=i2s=on
#dtparam=spi=on

# Uncomment this to enable the lirc-rpi module
#dtoverlay=lirc-rpi

# Additional overlays and parameters are documented /boot/overlays/README

# Enable audio (loads snd_bcm2835)
dtparam=audio=off
dtoverlay=audioinjector-addons,i2s-mmap
dtoverlay=pi3-disable-bt
disable_splash=1

[pi3]
dtparam=sd_overclock=63
arm_freq=1200
arm_freq_min=600
core_freq=250
core_freq_min=250
h264_freq=300
isp_freq=250
v3d_freq=300
avoid_pwm_pll=1

[pi4]
# Enable DRM VC4 V3D driver on top of the dispmanx display stack
dtoverlay=vc4-fkms-v3d,cma-256,rpi-ft5406
max_framebuffers=2
over_voltage=6
arm_freq=2000
#core_freq=500
#gpu_freq=500
v3d_freq=600
gpu_mem=320
#arm_64bit=1

[all]
#gpu_mem=256
#dtoverlay=vc4-fkms-v3d,cma-256,rpi-ft5406
#max_framebuffers=2
Reply
#2
Alright, I have the volume slider working now after creating a SoftVol PCM to provide Master control.

The mute? button doesn't appear to do anything. How does the mute button work? Any pointers as to why it may not be working?

It might be nice to have two volume sliders that could be controlled by two separate MixerNames. Then I expect I could have one volume slider control output volume and a second volume slider to control input (mic) volume.

I'm curious about the way the OAP "Applications" are supposed to work. Am I correct in believing that OA "Applications" such as YouTube, Kodi, Chromium and Welle.io are not integrated in a way that allows pausing/muting their media playback when an incoming call occurs? And this is unlike AA which can pause any playing media in the event of a call coming in, right?

Here are my current sound config files:

/etc/asound.conf
Code:
pcm.softmaster {
type softvol
slave.pcm "default"
control.name "Master"
control.card 0
}

pcm.!default {
type asym
hint {
show on
description "Default ALSA Output+Input (AudioInjector Octo)"
}
playback.pcm {
type plug
slave.pcm "output"
}
capture.pcm {
type plug
slave.pcm "input"
}
}

ctl.!default {
type hw
card 0
}

pcm.output {
type route
slave.pcm "hw:0"
slave.channels 8;
ttable {
0.0 1
1.1 1
2.2 1
3.3 1
4.4 1
5.5 1
6.6 1
7.7 1
}
}

pcm.input {
type hw
card 1
}

ctl.output {
type hw
card 0
}

ctl.input {
type hw
card 1
}


/home/pi/.config/pulse/default.pa
Code:
#!/usr/bin/pulseaudio -nF
#
# This file is part of PulseAudio.
#
# PulseAudio is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# PulseAudio is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public License
# along with PulseAudio; if not, see <http://www.gnu.org/licenses/>.

# This startup script is used only if PulseAudio is started per-user
# (i.e. not in system mode)

.fail

### Automatically restore the volume of streams and devices
load-module module-device-restore
load-module module-stream-restore
load-module module-card-restore

### Automatically augment property information from .desktop files
### stored in /usr/share/application
load-module module-augment-properties

### Should be after module-*-restore but before module-*-detect
load-module module-switch-on-port-available

### Load audio drivers statically
### (it's probably better to not load these drivers manually, but instead
### use module-udev-detect -- see below -- for doing this automatically)
load-module module-alsa-sink device=softmaster tsched=0 channels=8 channel_map=front-left,front-right,rear-left,rear-right,front-center,lfe,side-left,side-right
load-module module-alsa-source device=hw:1 tsched=0 channels=1 channel_map=mono
#load-module module-oss device="/dev/dsp" sink_name=output source_name=input
#load-module module-oss-mmap device="/dev/dsp" sink_name=output source_name=input
#load-module module-null-sink
#load-module module-pipe-sink

### Automatically load driver modules depending on the hardware available
#.ifexists module-udev-detect.so
#load-module module-udev-detect tsched=0 ignore_dB=1
#.else
### Use the static hardware detection module (for systems that lack udev support)
#load-module module-detect
#.endif

### Automatically connect sink and source if JACK server is present
.ifexists module-jackdbus-detect.so
.nofail
load-module module-jackdbus-detect channels=2
.fail
.endif

### Automatically load driver modules for Bluetooth hardware
.ifexists module-bluetooth-policy.so
load-module module-bluetooth-policy
.endif

### Load several protocols
.ifexists module-esound-protocol-unix.so
load-module module-esound-protocol-unix
.endif
load-module module-native-protocol-unix

### Network access (may be configured with paprefs, so leave this commented
### here if you plan to use paprefs)
#load-module module-esound-protocol-tcp
#load-module module-native-protocol-tcp
#load-module module-zeroconf-publish

### Load the RTP receiver module (also configured via paprefs, see above)
#load-module module-rtp-recv

### Load the RTP sender module (also configured via paprefs, see above)
#load-module module-null-sink sink_name=rtp format=s16be channels=2 rate=44100 sink_properties="device.description='RTP Multicast Sink'"
#load-module module-rtp-send source=rtp.monitor

### Load additional modules from GSettings. This can be configured with the paprefs tool.
### Please keep in mind that the modules configured by paprefs might conflict with manually
### loaded modules.
.ifexists module-gsettings.so
.nofail
load-module module-gsettings
.fail
.endif

### Automatically restore the default sink/source when changed by the user
### during runtime
### NOTE: This should be loaded as early as possible so that subsequent modules
### that look up the default sink/source get the right value
load-module module-default-device-restore

### Automatically move streams to the default sink if the sink they are
### connected to dies, similar for sources
load-module module-rescue-streams

### Make sure we always have a sink around, even if it is a null sink.
#load-module module-always-sink

### Honour intended role device property
load-module module-intended-roles

### Automatically suspend sinks/sources that become idle for too long
#load-module module-suspend-on-idle

### If autoexit on idle is enabled we want to make sure we only quit
### when no local session needs us anymore.
.ifexists module-console-kit.so
load-module module-console-kit
.endif
.ifexists module-systemd-login.so
load-module module-systemd-login
.endif

### Enable positioned event sounds
load-module module-position-event-sounds

### Cork music/video streams when a phone stream is active
#load-module module-role-cork

### Modules to allow autoloading of filters (such as echo cancellation)
### on demand. module-filter-heuristics tries to determine what filters
### make sense, and module-filter-apply does the heavy-lifting of
### loading modules and rerouting streams.

load-module module-filter-heuristics
load-module module-filter-apply

### Make some devices default
#set-default-sink output
#set-default-source input
#set-card-profile 0 output:multichannel-output+input:multichannel-input
#set-default-sink alsa_output.platform-soc_sound.multichannel-output

/home/pi/.config/pulse/daemon.conf
Code:
# This file is part of PulseAudio.
#
# PulseAudio is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# PulseAudio is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public License
# along with PulseAudio; if not, see <http://www.gnu.org/licenses/>.

## Configuration file for the PulseAudio daemon. See pulse-daemon.conf(5) for
## more information. Default values are commented out.  Use either ; or # for
## commenting.

resample-method = soxr-vhq
flat-volumes = no

; daemonize = no
; fail = yes
; allow-module-loading = yes
; allow-exit = yes
; use-pid-file = yes
; system-instance = no
; local-server-type = user
; enable-shm = yes
; enable-memfd = yes
; shm-size-bytes = 0 # setting this 0 will use the system-default, usually 64 MiB
; lock-memory = no
; cpu-limit = no

; high-priority = yes
; nice-level = -11

realtime-scheduling = yes
realtime-priority = 9

; exit-idle-time = 20
; scache-idle-time = 20

; dl-search-path = (depends on architecture)

; load-default-script-file = yes
; default-script-file = /etc/pulse/default.pa

; log-target = auto
; log-level = notice
; log-meta = no
; log-time = no
; log-backtrace = 0

; resample-method = speex-float-1
; avoid-resampling = false
; enable-remixing = yes
; remixing-use-all-sink-channels = yes
; enable-lfe-remixing = no
; lfe-crossover-freq = 0

; flat-volumes = yes

; rlimit-fsize = -1
; rlimit-data = -1
; rlimit-stack = -1
; rlimit-core = -1
; rlimit-as = -1
; rlimit-rss = -1
; rlimit-nproc = -1
; rlimit-nofile = 256
; rlimit-memlock = -1
; rlimit-locks = -1
; rlimit-sigpending = -1
; rlimit-msgqueue = -1
; rlimit-nice = 31
; rlimit-rtprio = 9
; rlimit-rttime = 200000

; default-sample-format = s16le
; default-sample-rate = 44100
; alternate-sample-rate = 48000
; default-sample-channels = 2
; default-channel-map = front-left,front-right

; default-fragments = 4
; default-fragment-size-msec = 25

; enable-deferred-volume = yes
; deferred-volume-safety-margin-usec = 8000
; deferred-volume-extra-delay-usec = 0
Reply
#3
Would it be possible to add an option to OAP which allows us to specify the command that the mute button triggers?

I have the volume slider control working now using Softvol to provide a Master volume control.

However, the mute button doesn't work. I'm not sure what command is currently triggered by the mute button, but it doesn't work in my case.

Here are the mute commands that actually work for me:
amixer -q -D pulse sset Master mute
amixer -q -D pulse sset Master unmute
amixer -q -D pulse sset Master toggle

As an alternative, couldn't the mute button simply set the Master (or whichever MixerName is configured) volume to 0? Wouldn't that provide more compatibility than whatever you have currently implemented?
Reply
#4
(01-18-2020, 10:32 PM)ktb Wrote: Would it be possible to add an option to OAP which allows us to specify the command that the mute button triggers?

I have the volume slider control working now using Softvol to provide a Master volume control.

However, the mute button doesn't work. I'm not sure what command is currently triggered by the mute button, but it doesn't work in my case.

Here are the mute commands that actually work for me:
amixer -q -D pulse sset Master mute
amixer -q -D pulse sset Master unmute
amixer -q -D pulse sset Master toggle

As an alternative, couldn't the mute button simply set the Master (or whichever MixerName is configured) volume to 0? Wouldn't that provide more compatibility than whatever you have currently implemented?

OpenAuto Pro mutes mixer that is set as default or configured via MixerName property. If controlling volume level works but mutting does not, please double check your configuration (it looks like something is misconfigured). Otherwise Softvol might not be compatible with ALSA mutting functionality. There is no option to set custom mute command because OpenAuto Pro does not use any to mute the mixer - it uses ALSA directly. As an alternative you can create an Application shortcut inside OpenAuto Pro - please refer to the user guide for more information.
Reply
#5
(01-18-2020, 11:57 PM)BlueWave Wrote:
(01-18-2020, 10:32 PM)ktb Wrote: Would it be possible to add an option to OAP which allows us to specify the command that the mute button triggers?

I have the volume slider control working now using Softvol to provide a Master volume control.

However, the mute button doesn't work. I'm not sure what command is currently triggered by the mute button, but it doesn't work in my case.

Here are the mute commands that actually work for me:
amixer -q -D pulse sset Master mute
amixer -q -D pulse sset Master unmute
amixer -q -D pulse sset Master toggle

As an alternative, couldn't the mute button simply set the Master (or whichever MixerName is configured) volume to 0? Wouldn't that provide more compatibility than whatever you have currently implemented?

OpenAuto Pro mutes mixer that is set as default or configured via MixerName property. If controlling volume level works but mutting does not, please double check your configuration (it looks like something is misconfigured). Otherwise Softvol might not be compatible with ALSA mutting functionality. There is no option to set custom mute command because OpenAuto Pro does not use any to mute the mixer - it uses ALSA directly. As an alternative you can create an Application shortcut inside OpenAuto Pro - please refer to the user guide for more information.
I don't believe that there is anything misconfigured. I need to be able to use a softvol Master control with this sound card because it does not provide a Master mixer control on its own. I believe you are correct that Softvol does not work with standard ALSA muting functionality.

That is why I am asking if you will please support this alternative use case. I would do it myself if I had access to the source code.

Sure, I could create an application shortcut to run the working mute command examples I posted here, but that wouldn't be very helpful. The mute functionality should be as easily accessible as the volume slider control. Adding an application shortcut still leaves me with a worthless non-functional mute button in the UI next to the volume slider control and that application shortcut would leave me without any visual indication in the UI as to whether or not the volume is currently muted or not.

If standard mute functionality did work with this sound card, would that allow OAP to mute/pause media playback in applications such as Kodi and Chromium when a HFP phone call is received and in progress in OAP (not Android Auto which already can mute media playback during a phone call)? Or is that just a current shortcoming of OAP for every user? Is a user really expected to stop/pause any sound coming from external applications like Kodi, Chromium or welle.io manually when they want to answer an incoming phone call in OAP?

I suppose I may add a push-button rotary encoder to my project and I CAN use that to control voume by physically turning it and I could call my required mute commands when it is physically pressed down.

I'd also be willing to pay for extended support if you were able to support my use case.
Reply
#6
Kodi and Chromium are 3rd party applications that do not support audio stream corking when voice call is active. That is not a matter of OpenAuto Pro but Kodi and Chromium to implement proper corking functionality. Please try to contact developers of mentioned applications or create a bug request on their bug trackers.

Regarding muting functionality - we use standard ALSA API that should be supported by software that you are using. Unfortnately, we cannot create "hacks" to make every software working. Rather we suggest to contact Softvol developers and ask why muting does not work using standard ALSA API calls. Also as far as we know, Softvol is an open source software, so having access to the source code, you can try to fix your problem (where it really is).
Reply
#7
(Yesterday, 01:00 AM)BlueWave Wrote: Kodi and Chromium are 3rd party applications that do not support audio stream corking when voice call is active. That is not a matter of OpenAuto Pro but Kodi and Chromium to implement proper corking functionality. Please try to contact developers of mentioned applications or create a bug request on their bug trackers.
Fair enough.

(Yesterday, 01:00 AM)BlueWave Wrote: Regarding muting functionality - we use standard ALSA API that should be supported by software that you are using. Unfortnately, we cannot create "hacks" to make every software working. Rather we suggest to contact Softvol developers and ask why muting does not work using standard ALSA API calls. Also as far as we know, Softvol is an open source software, so having access to the source code, you can try to fix your problem (where it really is).
Well, it is disappointing to hear that you are unwilling to support my use case, but I appreciate the reply. Unfortunately, I fear the chances of getting ALSA developers to add mute functionality in the softvol plugin are very low. It would be a lot easier to add the ability in OAP to trigger a custom mute command when the mute button is pressed or to set the Master volume to 0% when the mute button is pressed and restore the volume level when mute is pressed again, but I don't have access to the OAP source code. Thanks anyway. I'll update the thread with information if I ever get anywhere further with getting the mute button to work.

I did attempt to chain a default plug type PCM -> softvol Mute Switch (resolution 2) -> softvol Master Volume -> asym plug PCMs -> route type PCM -> hw type PCM. This seemed to work (mute button works), but unfortunately the Master volume control is then seemingly independent of the underlying slaves.  So, adjusting Master volume in this case does raise and lower volume and mute works, but Master volume set to 0% still produces some sound. Sad
Code:
pcm.!default {
    type plug
    slave.pcm "softmute"
}

pcm.softmute {
    type            softvol
    slave.pcm    "softvolume"
    control.name    "Master Switch"
    control.card    0
    resolution    2
}

pcm.softvolume {
    type            softvol
    slave.pcm    "defaultinputoutput"
    control.name    "Master"
    control.card    0
}

pcm.defaultinputoutput {
    type asym
    hint {
        show on
        description "Default ALSA Output+Input (AudioInjector Octo)"
    }
    playback.pcm {
        type plug
        slave.pcm "output"
    }
    capture.pcm {
        type plug
        slave.pcm "input"
    }
}

ctl.!default {
    type hw
    card 0
}

pcm.output {
    type route
    slave.pcm "hw:0"
    slave.channels 8;
    ttable {
        0.0 1
        1.1 1
        2.2 1
        3.3 1
        4.4 1
        5.5 1
        6.6 1
        7.7 1
    }
}

pcm.input {
    type hw
    card 1
}

ctl.output {
    type hw
    card 0
}

ctl.input {
        type hw
        card 1
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)