Add Features to Linphone App
Budget: $30 – $250 USD
I need the open-source Linphone client modified please read https://docs.google.com/document/d/15GjPnxmkQudnO30yjq3IJigO14ptkA4FRHSWEkSoY9A/edit?usp=sharing
Main Linphone Android GitHub (THIS IS THE ONE YOU MODIFY)
Linphone Android App
GitHub:
https://github.com/BelledonneCommunications/linphone-android
This is the official Linphone Android client (Kotlin + Java) where you will enforce audio routing.
Key Submodules You MUST Modify (Critical)
Linphone uses native C/C++ + Java/Kotlin, so forcing audio jack requires changes in both layers.
Android Audio Routing (Java / Kotlin layer)
Path
linphone-android/
└── app/src/main/java/org/linphone/core/tools/
Files to edit
• AndroidAudioManager.kt
• AudioRouteUtils.kt
• AudioDevices.kt
What to FORCE here
You must hard-lock wired headset:
audioManager.isSpeakerphoneOn = false
audioManager.stopBluetoothSco()
audioManager.isBluetoothScoOn = false
audioManager.mode = AudioManager.MODE_IN_COMMUNICATION
Then reject all routes except WIRED_HEADSET / WIRED_HEADPHONES.
Core Audio Engine (C/C++) – HARD ENFORCEMENT
Path
linphone-android/
└── submodules/linphone/
└── coreapi/
Files to modify
coreapi/audio_device.c
coreapi/audio_device.h
What to do
Disable everything except AUDIO_DEVICE_WIRED_HEADSET
Example logic:
if (device->type != LinphoneAudioDeviceTypeWiredHeadset) {
return FALSE; // reject speaker, earpiece, bluetooth
}
MediaStreamer2 (MOST IMPORTANT FOR LOOPBACK)
Path
linphone-android/
└── submodules/mediastreamer2/
Files to modify
src/android/androidsound.cpp
src/android/androidsound.h
Why this matters
This layer talks directly to Audio HAL.
You can force:
• Input → wired mic only
• Output → wired headset only
Example:
audio_source = AUDIO_SOURCE_MIC;
audio_stream_type = AUDIO_STREAM_VOICE_CALL;
Then block:
• AUDIO_DEVICE_OUT_SPEAKER
• AUDIO_DEVICE_OUT_EARPIECE
• AUDIO_DEVICE_OUT_BLUETOOTH_*
Disable Bluetooth at Compile Time (Recommended)
In:
mediastreamer2/src/android/androidsound.cpp
Remove or comment:
enableBluetoothSco();
Build System (NDK + Gradle)
You must rebuild:
• Linphone native core
• MediaStreamer2
• Android APK
Build guide (official)
https://gitlab.linphone.org/BC/public/linphone-android/-/blob/master/BUILD.md
Optional BUT STRONGLY RECOMMENDED (Your Use Case)
Because you're doing SIM ↔ SIP loopback on Redmi 4A:
Add a HARD FAIL if headset not connected
if (!audioManager.isWiredHeadsetOn) {
throw RuntimeException("WIRED HEADSET REQUIRED")
}
This prevents Android from silently switching routes.
Summary – Repos You Need
Purpose Repo
Android app https://github.com/BelledonneCommunications/linphone-android
SIP core submodules/linphone
Audio engine submodules/mediastreamer2
.
Experience with VoIP stacks, SIP, C/C++, Java/Kotlin or Objective-C/Swift, and familiarity with Belledonne’s build system will be key. Please let me know the most complex Linphone (or comparable VoIP) customization you have shipped and the timeline you’d propose for this one.
Main Linphone Android GitHub (THIS IS THE ONE YOU MODIFY)
Linphone Android App
GitHub:
https://github.com/BelledonneCommunications/linphone-android
This is the official Linphone Android client (Kotlin + Java) where you will enforce audio routing.
Key Submodules You MUST Modify (Critical)
Linphone uses native C/C++ + Java/Kotlin, so forcing audio jack requires changes in both layers.
Android Audio Routing (Java / Kotlin layer)
Path
linphone-android/
└── app/src/main/java/org/linphone/core/tools/
Files to edit
• AndroidAudioManager.kt
• AudioRouteUtils.kt
• AudioDevices.kt
What to FORCE here
You must hard-lock wired headset:
audioManager.isSpeakerphoneOn = false
audioManager.stopBluetoothSco()
audioManager.isBluetoothScoOn = false
audioManager.mode = AudioManager.MODE_IN_COMMUNICATION
Then reject all routes except WIRED_HEADSET / WIRED_HEADPHONES.
Core Audio Engine (C/C++) – HARD ENFORCEMENT
Path
linphone-android/
└── submodules/linphone/
└── coreapi/
Files to modify
coreapi/audio_device.c
coreapi/audio_device.h
What to do
Disable everything except AUDIO_DEVICE_WIRED_HEADSET
Example logic:
if (device->type != LinphoneAudioDeviceTypeWiredHeadset) {
return FALSE; // reject speaker, earpiece, bluetooth
}
MediaStreamer2 (MOST IMPORTANT FOR LOOPBACK)
Path
linphone-android/
└── submodules/mediastreamer2/
Files to modify
src/android/androidsound.cpp
src/android/androidsound.h
Why this matters
This layer talks directly to Audio HAL.
You can force:
• Input → wired mic only
• Output → wired headset only
Example:
audio_source = AUDIO_SOURCE_MIC;
audio_stream_type = AUDIO_STREAM_VOICE_CALL;
Then block:
• AUDIO_DEVICE_OUT_SPEAKER
• AUDIO_DEVICE_OUT_EARPIECE
• AUDIO_DEVICE_OUT_BLUETOOTH_*
Disable Bluetooth at Compile Time (Recommended)
In:
mediastreamer2/src/android/androidsound.cpp
Remove or comment:
enableBluetoothSco();
Build System (NDK + Gradle)
You must rebuild:
• Linphone native core
• MediaStreamer2
• Android APK
Build guide (official)
https://gitlab.linphone.org/BC/public/linphone-android/-/blob/master/BUILD.md
Optional BUT STRONGLY RECOMMENDED (Your Use Case)
Because you're doing SIM ↔ SIP loopback on Redmi 4A:
Add a HARD FAIL if headset not connected
if (!audioManager.isWiredHeadsetOn) {
throw RuntimeException("WIRED HEADSET REQUIRED")
}
This prevents Android from silently switching routes.
Summary – Repos You Need
Purpose Repo
Android app https://github.com/BelledonneCommunications/linphone-android
SIP core submodules/linphone
Audio engine submodules/mediastreamer2
.
Experience with VoIP stacks, SIP, C/C++, Java/Kotlin or Objective-C/Swift, and familiarity with Belledonne’s build system will be key. Please let me know the most complex Linphone (or comparable VoIP) customization you have shipped and the timeline you’d propose for this one.