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

sendReport method problem #116

Open
954514762 opened this issue Aug 31, 2023 · 6 comments
Open

sendReport method problem #116

954514762 opened this issue Aug 31, 2023 · 6 comments

Comments

@954514762
Copy link

SendReport parameters have to be two?
Like this selectedDevice.sendReport(reportId, reportData);

@nondebug
Copy link
Collaborator

Yes, there are two parameters to sendReport. The first parameter is the report ID, pass zero if the device does not use numbered reports. reportData contains the report data without the report ID byte.

What's the problem?

@954514762
Copy link
Author

Can carry multiple arguments

@954514762
Copy link
Author

Want to carry multiple parameters can achieve?

@chengweih001
Copy link
Contributor

Could you please elaborate an example how you wish sendReport to look like?

@954514762
Copy link
Author

For example: sendReport (args1 args2, data, length, end), custom and so on parameters, without limiting the number

@nondebug
Copy link
Collaborator

nondebug commented Sep 6, 2023

I don't understand how adding parameters would be useful.

What are args1 and args2 used for? If you're trying to send data to the device, it needs to be inside the reportData parameter which needs to follow the report layout defined in the device's report descriptor.

What are data, length, and end used for? There's already a reportData parameter which is a DataView so it already includes the extent.

Can you tell us more about the problem you're having that caused you to file this feature 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

No branches or pull requests

3 participants