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

Mic input not captured on specific device #570

Open
funkyidol opened this issue Dec 27, 2024 · 4 comments
Open

Mic input not captured on specific device #570

funkyidol opened this issue Dec 27, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@funkyidol
Copy link

funkyidol commented Dec 27, 2024

Describe the bug
Livekit SDK is not taking mic input on Galaxy A25 5G. Same build is working on other devices but not this specific device. There is no specific information in the logs that can point to any errors or issues.

Device Info:

  • Device: Galaxy A25 5G
  • OS: Android 14
  • LiveKit SDK version: 2.10.0, 2.11.0

Additional context
Please let me know how can I generate logs in order to help diagnose this issue.
Current Livekit config is setup as follows:

LiveKit.create(
                context,
                options =
                    RoomOptions(
                        audioTrackCaptureDefaults = LocalAudioTrackOptions(),
                        videoTrackCaptureDefaults =
                            LocalVideoTrackOptions(position = CameraPosition.BACK),
                    ),
                overrides =
                    LiveKitOverrides(
                        audioOptions = AudioOptions(audioOutputType = AudioType.MediaAudioType())
                    ),
            )

Another note is that the issue is not present when the audioOptions are not overriden and Livekit is used in default mode.

@funkyidol funkyidol added the bug Something isn't working label Dec 27, 2024
@funkyidol
Copy link
Author

There is a small update to the issue. After further testing we found out that the mic is operational but it only works when you speak very close to the mic even though we configured Livekit to be used in media mode. The moment the mic distance increases, it doesnt take the input.
LiveKitOverrides( audioOptions = AudioOptions(audioOutputType = AudioType.MediaAudioType())),

@safeer-ahmed
Copy link

+1

@safeer-ahmed
Copy link

In my case, there was another instance of AudioHandler i.e.
var audioHandler: AudioSwitchHandler = AudioSwitchHandler(applicationContext)

For some reason, stopping this audioHandler and then using the room's audioHandler, i.e., room.audioHandler leaves it in the buggy state of low-volume for recipients.

@davidliu
Copy link
Contributor

davidliu commented Apr 2, 2025

Only one audio handler should be used at a time. If you're creating your own, that one should be passed in when creating the Room for it to handle. This is due to the audio handler changing AudioManager settings behind the scenes, and multiple AudioHandlers will not be able to sync state with each other.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants