psychopy.org | Reference | Downloads | Github

Could I record sound without specifying the duration of it?

The record method of the class AdvAudioCapture and AduioCapture must be passed a sec arg to specify the duration of the sound to be recorded, while I want to just record until I call the stop method to let it stop cause in many cases I don’t know how long the sound will be.

So, is it possible? Or I can only pass a big enough duration value to it?

I ended up passing a large value to record, and then calling stop when I wanted to stop the recording.
Unfortunately I had some bugs with the pyo module, but maybe it works for you.

Yeap! That’s what I’m doing!