I never tried to change it, so I would think it is the default 25kHz which the docs say is the default for STM32 chips. Yeah I should try changing it, see if it makes any discernible difference.
edit: tried changing it to 35000, it doubles current consumption (the capacitors and inductors are removed again) but has no impact on the noise. At least my code wasn’t being ignored. At this point I’m starting to suspect the intended waveform is the issue somehow. I tried changing the waveform type from sine to trapezoid etc but it sounds exactly the same, I think maybe my commanded changes are not being obeyed.