Sound cards keep changing order on boot which invalidates settings in asound.conf & snips.toml


I have a matrix voice and a usb-powered speaker connecte to my RPI B3+. The problem with this setup is that sometimes on boot matrix voice shows up as “card 1” and USB speaker as “card 2” and sometimes the other way round.

How can I make the sound card order fixed because if they change order on boot I have to edit asound.conf and snips.toml mike setting to make it work and change back if it switches again on next boot.

I’m quite sure there’s a way to tell linux at boot which card should be which so that the “hw{x,0)” setting stays valid on each reboot.

Unfortunately when it comes to module loading, boot_order, etc. my linux knowledge stops and google was not that helpful cause various distrubutions handle it differently. So I need a solution for Rpi B3+

Thanks for any help on this