In Python/Kivy audio_ffpyplayer is not playin instead of audio_sdl2

Solution for In Python/Kivy audio_ffpyplayer is not playin instead of audio_sdl2
is Given Below:

I want my project to play audio with only ffpyplayer instead of audio_sdl2. I added some stuff with a help of someone on this website and it worked on pc. But when I converted it to apk with buildozer, on my phone it doesn’t plays audio. The app works smoothly but without audio. Here’s my python code:

import os
os.environ["KIVY_AUDIO"] = "ffpyplayer"
import ffpyplayer
import kivy
from import App
from import SoundLoader

class MainWidget(MDFloatLayout):

    def __init__(self, **kwargs):
        self.path = "sounds/click_effect.wav" = SoundLoader.load(self.path)

    def play_on(self):
        click = SoundLoader.load('sounds/click_effect.wav')
        if click:

    def play_off(self):
        myapp.screen_manager.transition = SlideTransition(direction='left', duration=.25)

And here’s my kivy code:


        background_color: 0, 0, 0, 0
        pos_hint: {'x': .39, 'y': .1}
        size_hint: .28, .15
        on_press: root.play_on()
        on_release: root.play_off()

            id: my_image
            source: "icons/play.png"
            size: 350, 350
            allow_stretch: True
            allow_ratio: True
            keep_ratio: True
            center_x: self.parent.center_x
            center_y: self.parent.center_y

Aand here’s my buildozer.spec requirmentes:

# (list) Source files to include (let empty to include all the files)
source.include_exts = py,png,jpg,kv,atlas,wav,ttf,txt

#source.include_patterns = assets/*,images/*.png
source.include_patterns = icons/*.png,sounds/*.wav

# comma separated e.g. requirements = sqlite3,kivy
requirements = python3,kivy==2.0.0,ffpyplayer

enter image description here

Also I debugged the app and I found this when I click the button:

[WARNING] [Audio ] Unable to find a loader for </data/data/org.test.test/files/app/sounds/click_effect.wav>