Skip to content

How can I update the Query_devices() list during un stream to check if the recording device is still there ? #382

Closed
@Wawi36

Description

@Wawi36

Hello,

I have a question about updating sd.query_devices () during a Stream to implement a security in case the recording device plug-off accidentally.

I noticed and read in the old issue that Sounddevice froze the list of devices when initialized (du to PortAudio) [#125]

In issue #47 there is proposed to Terminate and Initialize Portaudio (I tried and it works) but the drawback is that all streams are closed (and it's a problem for continuous acquisition ).
So @melvyn2 and @refeved (in issue #125) proposed a solution, using 'hotplug fork'.
I didn't know what it was, so I investigated. At the end I couldn't figure how to use 'hotplug fork'.

Do someone know a way to update the query_devices without Terminate the PortAudio and without using 'hotplug fork'?
Or
Can someone explain me witch of the file in the links given by @melvyn2 and @refeved I should update in the PortAudio library/folder? And how to use it after?

Thank you
and have a nice day

PS : Between I'm a Windows user ^^

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions