-
Notifications
You must be signed in to change notification settings - Fork 28
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
Forked v2 for uvcc #66
Draft
joelpurra
wants to merge
33
commits into
makenai:master
Choose a base branch
from
joelpurra:v2
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Currently, each `controlTransfer` by setting `bmRequestType` targets the camera _interface_ rather than _device_. - Using an interface would require claiming it, which is not performed. - Claiming an interface would kill access for any other process which may be using the camera (including the kernel?). - This commit targets `controlTransfer` to the _device_ instead. - There might be better ways to transfer control commands. - Ported from `uvc-control` v1 to v2. Fixes makenai#58 Fixes joelpurra/uvcc#2 See - makenai#58 - joelpurra/uvcc#2
- Fixes typo which affected `CT` control types. Fixes joelpurra/uvcc#4 See - joelpurra/uvcc#4
- Possibly related to the previous commit which had a typo affecting camera input terminal (CT) controls. - There might be other bugs in the control data, should check against UVC v1.5 reference. Fixes makenai#60 See - makenai#60 - https://www.usb.org/documents?search=uvc
- Uses `readInt(...)` which was added then removed in previous commits. - Adds `readInts(...)` to get an array of values where necessary. See - makenai@4d420ff - makenai@bdb96da
This was referenced Sep 2, 2020
- Using `uvcc` has reportedly been slower than before. - Profiling shows that `uvcc export` finishes in circa 200 milliseconds, but there are several seconds of idling afterwards. No code lines are pointed out, and it seems to happen _after_ `uvcc` itself finished. - Investigating shows that `node-usb` v1.7.0 adds a 8 second delay during testing. - Pinning the `usb` version to v1.6.5 removes the idling delay. ```text 0.14s user 0.01s system 1% cpu 8.908 total ``` ```text 0.11s user 0.01s system 67% cpu 0.180 total ``` Fixes joelpurra/uvcc#16
For reals this time.
- Fixes compilation/compatibility with Node.js v17.
- Most of the tests use `async` calls via the wrapped `usb` device, wrapped in a mix of `sync` loops (usually `array.forEach()`) and "loose" promises (logging to `stdout`/`stderr`). - Execution of test files does not finish if the camera object is not explicitly closed after use, as the `usb` device is still open and active. - Because of the "loose" promises, there is no clear way to tell when the camera object is no longer in use. - This commit fixes affected tests by adding a top-level async `run()` wrapper function, and converting `.forEach()` loops to `for...of` loops with `await`ed camera device calls inside. The test files (like the rest of this project) uses a mix of outdated code styles. The upstream refactoring from v1 to v2 was never completed, and left in a messy state. All code should obviously be fixed "at some point", but since the upstream project has been dead for years I've avoided it in this fork. While I need this code to work for `uvcc` to work, fixing and cleaning up all (any!) of it more than necessary is not a priority. Patches welcome
Reduces the number of (developer) dependencies (as well as related security warnings) for the main `uvc-control` package.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In order to progress with
uvcc
, I am using a forkeduvc-control
based onmaster
(ca1e2c9). There are bugfixes and improvements to get feature-parity withuvc-control
v1. Might add new stuff if deemed useful.It'd be better to have everything merged to (and published from)
uvc-control
, so here's a pull request for tracking progress. It'll be a draft for now; can be split into multiple pull requests later if changes are of interest.See
uvcc
, which wrapsuvc-control
in a command line tool.