Commit graph

757 commits

Author SHA1 Message Date
Juho Hämäläinen
1daab94724 build: Expat is mandatory. 2022-02-23 09:23:03 +02:00
Juho Hämäläinen
0898217179 Bump packaging version. 2022-02-21 09:34:20 +02:00
Juho Hämäläinen
dbc7d678bb
Merge pull request #112 from jusa/new-api
New API for calling HAL functions.
2022-02-21 09:31:03 +02:00
Juho Hämäläinen
ef56dd4964 README: Add section about pa_shared based API. 2022-02-18 15:45:32 +02:00
Juho Hämäläinen
1cc2a0822e common: New API for calling HAL functions.
New pa_shared based API for calling HAL functions so that other modules
needing these functions don't need to link with libdroid.

[common] New API for calling HAL functions. JB#55832
2022-02-18 15:45:32 +02:00
Juho Hämäläinen
8df3961333
Merge pull request #111 from g7/for-upstream/mer-hybris/no-channels
common: Handle profiles with no supported channels
2022-02-18 15:10:19 +02:00
Eugenio Paolantonio (g7)
b23e20db5c common: Handle profiles with no supported channels
When a profile doesn't have any supported channels, pa_conversion_parse_*_channels
returns false even though the parsing itself succeeded.
This in turn makes the parsing to be aborted altogether.

Handle this case by properly ignoring the profile.

This commit changes the pa_conversion_parse_*_channels functions so that
they return the channel count, or -1 if the parsing has been unsuccessful.

[common] Handle profiles with no supported channels

Signed-off-by: Eugenio Paolantonio (g7) <me@medesimo.eu>
2022-02-18 13:15:21 +01:00
Eugenio Paolantonio (g7)
0886d509fc Merge tag 'upstream/14.2.93' into feature/bookworm/upgrade-14.2.93 2022-01-30 19:10:35 +01:00
Eugenio Paolantonio (g7)
80015ede82 [pulseaudio-modules-droid] Move to bookworm
Signed-off-by: Eugenio Paolantonio (g7) <me@medesimo.eu>
2021-12-08 16:19:04 +01:00
Juho Hämäläinen
9c6842e7d9 Bump packaging version. 2021-10-08 15:43:09 +03:00
Juho Hämäläinen
0d739ca587
Merge pull request #109 from jusa/jb55711
Use more generic stream property for audio source.
2021-10-08 15:42:31 +03:00
Juho Hämäläinen
1781dab3b8 common: Use more generic stream property for audio source.
[common] Use more generic stream property for audio source. JB#55711
2021-10-08 15:20:58 +03:00
Juho Hämäläinen
98d2c7358a Bump packaging version. 2021-10-08 08:32:35 +03:00
Juho Hämäläinen
11a09b005d
Merge pull request #108 from jusa/jb55711
Enable custom audio sources with input streams.
2021-10-08 08:31:12 +03:00
Juho Hämäläinen
d9e2ddfd72 common: Fix segfault with adaptations which assume empty adress is not NULL.
Some adaptations don't check for NULL before using the address which
leads to a crash. Let's just use empty string for address.

[common] Fix segfault with adaptations which assume empty adress is not NULL. Fixes JB#55831
2021-10-08 08:30:12 +03:00
Juho Hämäläinen
baecfc7cdd source: Use source-output proplist when reconfiguring input stream.
Use updated functions from common which utilize proplist when reconfiguring
input stream.

[source] Use source-output proplist when reconfiguring input stream. JB#55711
2021-10-07 12:06:31 +03:00
Juho Hämäläinen
2d7ee841ed common: Allow custom audio source based on property.
When reconfiguring input stream set custom audio source if one
is defined in droid.input.source property. Allowed values are
audio source fancy names listed in
string_conversion_table_audio_source_fancy.

[common] Allow custom audio source based on property. JB#55711
2021-10-07 12:04:52 +03:00
Juho Hämäläinen
4103c31aec common: Add generic converter for fancy audio sources.
[common] Add generic converter for fancy audio sources.
2021-10-07 12:00:59 +03:00
Adam Boardman
a5477e617b Build fix 2021-06-30 19:14:32 +01:00
Adam Boardman
130edc502b Merge remote-tracking branch 'upstream/master' into bullseye 2021-06-18 20:48:34 +01:00
Juho Hämäläinen
8283bbe5c9 Bump packaging version. 2021-05-06 13:11:14 +03:00
Juho Hämäläinen
42af5e85c5
Merge pull request #107 from jusa/jb53992
Add quirks standby_set_route and speaker_before_voice.
2021-05-06 13:10:28 +03:00
Juho Hämäläinen
a676accf88 common: Add quirk speaker_before_voice.
Set route to speaker before changing audio mode to AUDIO_MODE_IN_CALL.
Some devices don't get routing right if the route is something else
(like AUDIO_DEVICE_OUT_WIRED_HEADSET) before calling set_mode().

[common] Add quirk speaker_before_voice. JB#53992
2021-05-05 16:05:36 +03:00
Juho Hämäläinen
446ac62a6e common: Add quirk standby_set_route.
Some devices don't like to receive set_parameters() call while they
are in write(), even if it seems the mutexes are correctly in place.
Standby is another synchronization point which seems to work better.

[common] Add quirk standby_set_route. JB#53992
2021-05-05 16:02:51 +03:00
Adam Boardman
930e65658c Fix for presense detection of headset plugging which only reports presence/absense of the microphone part, relates to gemian/gemian#7 2021-05-02 17:06:46 +01:00
Juho Hämäläinen
edec25347e Bump packaging version. 2021-04-22 15:40:52 +03:00
Juho Hämäläinen
8f936ba66f
Merge pull request #104 from jusa/bt_sco
Set BT_SCO parameter for Bluetooth routes.
2021-04-22 15:39:48 +03:00
Juho Hämäläinen
5be0189b91 common: Set BT_SCO parameter for Bluetooth routes.
Some adaptations need parameter BT_SCO set before enabling Bluetooth
HFP/HSP routes. It should be fine to set this parameter for adaptations
which don't need it as they would just ignore a parameter that is
unknown.

[common] Set BT_SCO parameter for Bluetooth routes. Fixes JB#53996
2021-04-21 22:59:19 +03:00
Juho Hämäläinen
38b07e6d45 Bump packaging version. 2021-03-25 21:43:13 +02:00
Juho Hämäläinen
eac4b34d39
Merge pull request #103 from jusa/volume_control
Avoid segfault when voice call starts with deferred volume.
2021-03-25 21:42:14 +02:00
Juho Hämäläinen
3f1cc042bc sink: Avoid segfault when voice call starts with deferred volume.
Calling pa_sink_set_write_volume_callback() from main
thread changes a callback pointer in pa_sink which is
accessed from io thread.

When audio is playing and voice call starts there is a
window where the callback is changed to NULL while io
thread is using it, causing a segfault.

[sink] Avoid segfault when voice call starts with deferred volume. JB#53687
2021-03-25 13:52:56 +02:00
Eugenio Paolantonio (g7)
c6da10943a [ci] Updated to match new name [CI SKIP]
Signed-off-by: Eugenio Paolantonio (g7) <me@medesimo.eu>
2021-03-24 00:39:36 +01:00
Juho Hämäläinen
b310103c0f Bump packaging version. 2021-03-23 18:11:06 +02:00
Juho Hämäläinen
898aacd38e
Merge pull request #102 from jusa/volume_control
Improvements to volume control.
2021-03-23 18:09:28 +02:00
Juho Hämäläinen
4414037c47 sink: Add option to prewrite silence always.
In some cases silence prewrite needs to be done even if the target
device is already active. In this case new "/always" modifier can
be used to enable prewriting always. For example:

prewrite_on_resume=deep_buffer=AUDIO_DEVICE_OUT_SPEAKER:2/always

[sink] Add option to prewrite silence always. JB#53590
2021-03-23 18:08:41 +02:00
Juho Hämäläinen
c9c66b4750 sink: Apply channel average volume to stream.
HAL implementations expect identical volume for both channels
anyway.

[sink] Apply channel average volume to stream. JB#53590
2021-03-23 18:08:02 +02:00
Juho Hämäläinen
65483884ae sink: Enable deferred volume for hw volume control.
Make sure volume changes are applied in between writing to hardware
to avoid volume glitches. As the writing is blocking we cannot synchronize
the changes from main thread easily so better to apply the changes
when nothing is written.

[sink] Enable deferred volume for hw volume control. JB#53590
2021-03-23 18:08:02 +02:00
Juho Hämäläinen
6ef0459669
Merge pull request #101 from jusa/cal
Add quirk for audio calibration.
2021-03-23 18:06:48 +02:00
Juho Hämäläinen
f01f0a53a7 source: Get hw module with new function in stand alone mode.
[source] Get hw module with new function in stand alone mode.
2021-03-18 11:54:12 +02:00
Juho Hämäläinen
997a9c87de sink: Get hw module with new function in stand alone mode.
[sink] Get hw module with new function in stand alone mode.
2021-03-18 11:53:53 +02:00
Juho Hämäläinen
0cd9a16bee README.md: Markdown formatting fixes. 2021-03-18 11:44:57 +02:00
Juho Hämäläinen
45badd1a75 README.md: Rename from README. 2021-03-18 11:44:57 +02:00
Juho Hämäläinen
cb40bac4c5 README: Add notes about audio_cal_wait quirk. 2021-03-18 11:44:57 +02:00
Juho Hämäläinen
b7cbd0ef3d source: Fix format specifiers. 2021-03-18 11:44:57 +02:00
Juho Hämäläinen
9cad56c426 sink: Fix format specifiers. 2021-03-18 11:44:57 +02:00
Juho Hämäläinen
9517a067de common: Fix format specifiers. 2021-03-18 11:44:57 +02:00
Juho Hämäläinen
9282a566c8 common: Add quirk audio_cal_wait.
If there is a device which runs threaded audio calibration after hw
module open we need to wait for a while after opening the first output
stream.

Also when the calibration is already done and we are starting we again
need to wait for a while for the calibration loading to finish.

[common] Add quirk audio_cal_wait. JB#52328
2021-03-18 11:44:54 +02:00
Juho Hämäläinen
7bb06f6a30 card: Parse quirks while loading hw module.
Parse quirks while loading hw module using new pa_droid_hw_module_get2().

[card] Parse quirks while loading hw module. JB#52328
2021-03-18 11:44:09 +02:00
Juho Hämäläinen
501d881534 common: Refactor quirks parsing.
Right now quirks can be used only after hw module is created.
In order to have quirks in the hw module loading phase as well
we need to have a mechanism to have quirk parsing earlier.

[common] Refactor quirks parsing. JB#52328
2021-03-18 11:44:03 +02:00
Eugenio Paolantonio (g7)
74c17e4dab [packaging] pulseaudio-modules-droid-dev: fix dependency on pulseaudio-modules-droid
Signed-off-by: Eugenio Paolantonio (g7) <me@medesimo.eu>
2021-03-13 19:18:47 +01:00