Is it possible to generate sound in UPBGE?

I wonder if this is possible - generating sound in UPBGE via python and playing it. I’m not talking about files here, but realtime procedural audio, for example, a curtain fluttering in the wind, or wind blowing intermittently.

Or am I stuck with sound files for now?


Hold Space for Sinus-Tone
Hold T for Tetris-melody

Audaspace Tutorial:
Tetris code from here:

UPBGE03_SoundGen.blend (829.8 KB)

Is Audaspace included in UPBGE, or is it a downloadable addon?

It’s included.
Somehow it’s missing in the UPBGE-documentation but here it is for Blender: