I am not sure where the problem is. But I think it is a problem with my application which I built on the media3 library. I tried other applications such as Musicolet which uses an older version of the Media library, and everything is fine there. I also used Media Controller Tester to test my application. The application is correctly detected as an application with the Auto supported implementation. It passes all tests correctly, the media library is also correctly detected. Now let's move on to Android Auto. For testing I use Android Auto - Desktop Head Unit. Connection via USB. My application is correctly detected there, the media is also displayed. Unfortunately, during playback there is no sound from the computer speakers or from the phone speakers. The progress bar moves forward but without sound. Sometimes it happens that the sound is there for a moment and then disappears. When the sound disappears, the console displays the message:
[I]: Audio stream close, buffered = 53248
, and when the sound is played, the message:
[W]: Audio start: Audio stream already playing.
Here I also tried the Musicolet application and the problem does not occur, the sound plays without interruptions. Is there something I need to additionally implement in my application so that the streaming does not close?
I am not sure where the problem is. But I think it is a problem with my application which I built on the media3 library. I tried other applications such as Musicolet which uses an older version of the Media library, and everything is fine there. I also used Media Controller Tester to test my application. The application is correctly detected as an application with the Auto supported implementation. It passes all tests correctly, the media library is also correctly detected. Now let's move on to Android Auto. For testing I use Android Auto - Desktop Head Unit. Connection via USB. My application is correctly detected there, the media is also displayed. Unfortunately, during playback there is no sound from the computer speakers or from the phone speakers. The progress bar moves forward but without sound. Sometimes it happens that the sound is there for a moment and then disappears. When the sound disappears, the console displays the message:
[I]: Audio stream close, buffered = 53248
, and when the sound is played, the message:[W]: Audio start: Audio stream already playing.
Here I also tried the Musicolet application and the problem does not occur, the sound plays without interruptions. Is there something I need to additionally implement in my application so that the streaming does not close?