Sound error - not constant sound

Hello Thunkable


i want to make a metronome.

but when i click the start button, the sound’s beat not constant.

do you know why is it happen?

Thank you.

1 Like

Playing a sound involves the Thunkable app to issue a request to the operating system to play the sound using the driver. There is no guarantee that the request to start the sound will be done with a constant delay from request to playback, since those operations are asynchronous. It is like mailing a letter, you will know it will get there, you will know it will get there before a certain time, but that time can vary.

Hi there,

This is what I would recommend for blocks to make a sound play on a loop:
image

It will still be the case that there is a small gap between the sound ending and the new sound starting.

Have you tried getting a sound that is a single ‘click’ and playing it on repeat with a ‘wait seconds’ block between loops? (The amount of seconds can be less than 1 if expressed as a decimel). It could be easier to make an app that compensates for the delay that way.

1 Like

“Recursive Function” :nerd_face:
This thing helps a lot :+1:

Thanks! :blush:

1 Like