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

libbladeRF: Can't probe for already opened device when using CyUSB backend #364

Closed
jynik opened this issue Jan 21, 2015 · 3 comments
Closed
Assignees
Labels
Issue: Bug It's a bug and it oughta be fixed
Milestone

Comments

@jynik
Copy link
Contributor

jynik commented Jan 21, 2015

When a bladeRF is already opened using the Cypress backend, attempting to probe for a device will fail to report the currently opened device.

This is because we attempt to open the device to gather information about it. However, we use a global lock to ensure the device isn't used by multiple processes. This prevents us from gathering the probe information.

This is most easily observed via bladeRF-cli:

  • Open a device via bladeRF-cli -i
  • Run the probe command in interactive mode.
@jynik jynik added the Issue: Bug It's a bug and it oughta be fixed label Jan 21, 2015
@jynik jynik added this to the 2015.01-rc2 milestone Jan 22, 2015
@jynik jynik self-assigned this Jan 22, 2015
@mambrus
Copy link
Contributor

mambrus commented Jan 22, 2015

I think this could be the same case that I occasionally see. Use-case is different but end-result sounds very similar to me. Please advise with technical info about what's going on and I'll try to confirm.

jynik added a commit that referenced this issue Jan 23, 2015
Using open_device() is overkill, as we just want to open a device handle to
read member variables for VID, PID, and serial #; we're not writing to the
device.

*NOTE:* The CyAPI docs say that this will Close() the device first if
        needed. This may be a bogus "fix" for #364, if the already opened device
        handle is beings used when the probe() is called.
jynik added a commit that referenced this issue Jan 23, 2015
Using open_device() is overkill, as we just want to open a device handle to
read member variables for VID, PID, and serial #; we're not writing to the
device.

This addresses issue #364.
@jynik
Copy link
Contributor Author

jynik commented Jan 23, 2015

@mambrus This was specific to the Cypress backend. Definitely different if you're using libusb in Linux. Want to open a new issue for whatever symptoms you're seeing, or is it too early for that?

@jynik
Copy link
Contributor Author

jynik commented Jan 23, 2015

Addressed in 5d49a7b.

@jynik jynik closed this as completed Jan 23, 2015
jenselofsson pushed a commit to jenselofsson/bladeRF that referenced this issue Feb 2, 2015
Using open_device() is overkill, as we just want to open a device handle to
read member variables for VID, PID, and serial #; we're not writing to the
device.

This addresses issue Nuand#364.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue: Bug It's a bug and it oughta be fixed
Projects
None yet
Development

No branches or pull requests

2 participants