I am trying to get sound out from a Raspberry Pi zero with RaspiOS bullseye. I have enabled the alternate functions and use a RC filter to get an audio signal to some earbuds. However when I try to play anything using aplay it doesn't work.
I have the following clues:
I made sure that dtparam=audio=on is present on config.txt.
When I try to force 3.5mm from raspi-config menu it seems that there is some problem. When I click "S2 Audio" the screen flashes for a few seconds and it goes back to the main raspi-config page.
When I try alsamixer I only get HDMI as an option. The same happens when I run aplay -l
Any idea on what can be wrong? I tried reinstalling the OS several times and it didn't help.