Android Question Acoustic Echo Canceler

KZero

Active Member
Licensed User
Longtime User
Hello,

i'm trying to get this code working for long time with no avail

test project attached with AudioStreamer (real time record and playack) to know if the code is working
** just increase the voice call volume to max and start talk bit loudly to determine if the echo canceler is working or not

more info about Acoustic echo canceler : https://developer.android.com/reference/android/media/audiofx/AcousticEchoCanceler.html
B4X:
Sub SetEchoCanceler
   Dim echo As JavaObject
   echo.InitializeStatic("android/media/audiofx/AcousticEchoCanceler".Replace("/", "."))
   If echo.RunMethod("isAvailable", Null) = True Then
     Dim r As Reflector
     r.Target = streamer
     Dim AudioRecord As JavaObject = r.GetField("audioRecord")
   echo=   echo.RunMethod("create", Array(AudioRecord.RunMethod("getAudioSessionId", Null)))
     echo.RunMethod("setEnabled" , Array As Object(True))
     ToastMessageShow("echo set" , True)
   Else
    ToastMessageShow("Echo not available",False)
   End If
End Sub

i wish anyone can help with it or any available working alternative
 

Attachments

  • echo_test.zip
    7.7 KB · Views: 304
Top