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

Low Latency Input on Galaxy Note 20 is silent #1229

Open
philburk opened this issue Mar 21, 2021 · 5 comments
Open

Low Latency Input on Galaxy Note 20 is silent #1229

philburk opened this issue Mar 21, 2021 · 5 comments
Assignees
Labels
bug P1 high priority quirk Device specific behaviour which requires a quirk/workaround in Oboe Samsung specific to Samsung devices

Comments

@philburk
Copy link
Collaborator

See discussion at #1228

@philburk philburk added the bug label Mar 21, 2021
@philburk
Copy link
Collaborator Author

What are the other parameters for the stream?

Is it a US device (Qualcomm) or an Exynos device? What is the model number?

What is the Android version?

I tested with OboeTester application,
In TEST INPUT, please try turning off MMAP.

Also try the DATA PATHS in OboeTester. It will check for dead inputs. it needs to be run in a quiet room with the volume up to about 80%.

@ashfaq-opn
Copy link

ashfaq-opn commented Mar 21, 2021

For me the other parameters are,

API: AAudio
Format: I16
Sharing Mode: Exclusive
Preset: oboe::InputPreset::VoicePerformance
Device ID: kUnspecified
Direction: Input
Channel count: Stereo
Sample rate: 48000

I didn't set any other option.

I tried turning MMAP on and off in Oboe Tester. It didn't help. Still getting a DC value.

The device details are below,

Android Version: 11
Model: SM-N981B/DS
Chipset: Exynos 990

I tried the Data Paths in OboeTester, in a quiet room with full volume. Attaching the result below:

data_paths_test_samsung_note20_1229.txt

@philburk
Copy link
Collaborator Author

Thanks for running the Data Paths test! That is very helpful.
I can see that every MMAP input test for DATA PATHS is failing.
Also it is skipping all the MMAP output tests.
I will contact Samsung about this.

This is probably related to #892
Both the S20 and the Note20 use the Exynos 990.

There was a quirk added to Oboe 1.5.1 for Exynos 990 in #1172 that would disable MMAP.
Is your app running Oboe 1.5.1? This should have disabled MMAP on your device

The Oboe Workarounds and QuirkManager can be disabled from the main screen in OboeTester so that we can test either way.

Maybe the changelist is different for Note 20. What do you get for:

adb shell getprop ro.build.changelist

I tried turning MMAP on and off in Oboe Tester. It didn't help. Still getting a DC value.

I think the OboeTester UI misled you. The MMAP checkbox is only read at the OPEN. Toggling MMAP after opening has no effect. I will disable the checkbox after Open. #1233

@philburk philburk added P1 high priority Samsung specific to Samsung devices labels Mar 24, 2021
@ashfaq-opn
Copy link

ashfaq-opn commented Mar 25, 2021

@philburk Thank you very much for your help in this. For now I decided to turn off LowLatency mode for recording. When this issue will be resolved I will turn back it On.

I am using the latest commit from master branch in Oboe. So yes, 1.5.1.

I basically unchecked the MMAP checkbox before OPEN. Today I tried again. From main screen I tried enabling "Oboe Workarounds" then went to "Test Input", unchecked the box "MMAP" and then I hit Open and then Start. Still it is capturing no sound.

I can see that every MMAP input test for DATA PATHS is failing.
Also it is skipping all the MMAP output tests.

As the problem is with MMAP, is there any way to turn that off before stream creation in Oboe?

The command you mentioned gives me the following output.

./adb shell getprop ro.build.changelist
20939149

@philburk
Copy link
Collaborator Author

unchecked the box "MMAP" and then I hit Open and then Start. Still it is capturing no sound.

That suggests the problem is not just with MMAP. But the data paths test indicate it is an MMAP problem.

is there any way to turn [MMAP] off before stream creation in Oboe?

The API is not exposed, but there is a class in the aaudio folder.
https://github.com/google/oboe/blob/master/src/aaudio/AAudioExtensions.h
Call:

    AAudioExtensions::getInstance().setMMapEnabled(false);

Please let me know if that solves the problem.

@philburk philburk added the quirk Device specific behaviour which requires a quirk/workaround in Oboe label Jul 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug P1 high priority quirk Device specific behaviour which requires a quirk/workaround in Oboe Samsung specific to Samsung devices
Projects
None yet
Development

No branches or pull requests

2 participants