startEchoTest

Starts an audio device loopback test.

Future<void> startEchoTest(EchoTestConfiguration config);

Details

To test whether the user's local sending and receiving streams are normal, you can call this method to perform an audio and video call loop test, which tests whether the audio and video devices and the user's upstream and downstream networks are working properly.

After starting the test, the user needs to make a sound or face the camera. The audio or video is output after about two seconds. If the audio playback is normal, the audio device and the user's upstream and downstream networks are working properly; if the video playback is normal, the video device and the user's upstream and downstream networks are working properly.
Attention:
  • You can call this method either before or after joining a channel. When calling in a channel, make sure that no audio or video stream is being published.
  • After calling this method, call stopEchoTest to end the test; otherwise, the user cannot perform the next audio and video call loop test and cannot join the channel.
  • In live streaming scenarios, this method only applies to hosts.

Parameters

config
The configuration of the audio and video call loop test. See EchoTestConfiguration.

Returns

  • 0: Success.
  • < 0: Failure.