Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simultaneously Probe Serial Ports for NDI devices #62

Open
rajkundu opened this issue Dec 29, 2022 · 2 comments · May be fixed by #63
Open

Simultaneously Probe Serial Ports for NDI devices #62

rajkundu opened this issue Dec 29, 2022 · 2 comments · May be fixed by #63

Comments

@rajkundu
Copy link
Contributor

Currently, it takes about 5-10 seconds to initialize an NDI camera on my computer (16" Intel MacBook Pro, macOS 12.5). This is because of the following code, which sequentially probes serial ports for NDI devices:

for port_no in range(ports_to_probe):
name = serial_ports[port_no].device
result = ndicapy.ndiProbe(name)
print("Probing port: ", port_no, " got name: ", name,
" Result: ", result, file=fileout)
if result == ndicapy.NDI_OKAY:
break

Therefore, on my computer, serial port 0 (/dev/cu.BLTH) is always unnecessarily probed before serial port 1 (/dev/cu.usbserial-144130, the NDI Camera).

The current best workaround is to set configuration['serial port'] = '/dev/cu.usbserial-144130'. This works fine, but it would be nice to have functionality which probes serial ports simultaneously and returns as soon as any NDI device is found.

@rajkundu rajkundu linked a pull request Dec 29, 2022 that will close this issue
@rajkundu
Copy link
Contributor Author

rajkundu commented Jan 6, 2023

Any thoughts on this?

@thompson318
Copy link
Collaborator

It sounds sensible, I just left a comment on the pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants