scratch icon indicating copy to clipboard operation
scratch copied to clipboard

scratch-15092015, sound 'pop'

Open heppg opened this issue 10 years ago • 6 comments

as reported by by mob-i-l » 05 Oct 2015, 01:21 https://www.raspberrypi.org/forums/viewtopic.php?p=824627#p824627

Sound effects/pop is not reliably played. In a loop, forever: play sound 'pop' until done, the sound is not played. Other sounds work. This is reproducible in my 'jessie' raspbian environment.

When I play a longer sound 'in parallel', the forever-loop/ play sound "pop" is audible then. When the long sound terminates, the pop disappears too.

heppg avatar Oct 05 '15 04:10 heppg

That's curious... To add to the fun my primary development Pi decided to stop sending noises to the audio out socket whilst testing this. Rebooting didn't change anything. Sigh. A secondary testing Pi makes noises ok and 'meow' etc work ok but yes,, 'pop' just makes no sound - except that the sound system debug output says it does! And yes, the pop plays perfectly well when another longer running sound is playing. I wonder if something about the shortness is causing the problem. This may take a little puzzling over!

timrowledge avatar Oct 06 '15 19:10 timrowledge

(later) Yup, there's something about the amount of buffer data; if I stop the sound player from terminating the sound playing when there is no more data (err, that reads badly - the sound player loop fills in 0 data when there is no more 'real' data. We can detect that and suspend the player process) then the pop plays ok.

timrowledge avatar Oct 06 '15 19:10 timrowledge

Somewhere buried deep in the SoundPlayer code there is a mistake that is proving very difficult to find. I actually managed to get values set up so the pop would reliably play - and then it got out of sorts again.

timrowledge avatar Nov 11 '15 00:11 timrowledge

So far this is eluding us. The pop sounds ok if we have continuous playing on - but that leaves terrible pwm jitter hiss behind - or reverb on, which isn't so nice either. Works the same on iMac too, so at least it should be image fixable eventualy.

timrowledge avatar Jan 11 '16 22:01 timrowledge

Latest testing with the build intends for sept '16 release, built on the production Squeak 5.1 release appears to play the pop ok. Along with recent audio firmware and some Squeak work, I think this is fixed.

timrowledge avatar Aug 25 '16 02:08 timrowledge

Related to #218

timrowledge avatar Sep 13 '16 18:09 timrowledge