Hi,
You get to set the sampleRate in the audio context you use, for audio worklets samplerate is read only,
```
typedef int EMSCRIPTEN_WEBAUDIO_T;
typedef struct EmscriptenWebAudioCreateAttributes
{
const char *latencyHint; // Specify one of "balanced", "interactive" or "playback"
uint32_t sampleRate; // E.g. 44100 or 48000
} EmscriptenWebAudioCreateAttributes;
// Creates a new Web Audio AudioContext, and returns a handle to it.
EMSCRIPTEN_WEBAUDIO_T emscripten_create_audio_context(const EmscriptenWebAudioCreateAttributes *options);
```
from system/include/emscripten/webaudio.h
Hope it helps,