-
Notifications
You must be signed in to change notification settings - Fork 196
Algorithms for bluetooth.descriptor commands #662
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
Conversation
index.bs
Outdated
| 1. Set |params|[`"characteristicUuid"`] to |characteristic|'s <a>UUID</a>. | ||
| 1. Set |params|[`"descriptorUuid"`] to |descriptor|'s <a>UUID</a>. | ||
| 1. Set |params|[`"type"`] to |type|. | ||
| 1. If |type| is `write`, set |params|[`"data"`] to a [=new=] {{Uint8Array}} wrapping a [=new=] {{ArrayBuffer}} containing |bytes|. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I missed this in the previous PR but since params isn't a WebIDL type I don't think using a Uint8Array is correct here. Isn't there a CDDL type we should be initializing for a byte array?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated. Please see the latest patch.
I didn't find anything relative in CDDL spec, but I found one example in https://www.w3.org/TR/webdriver-bidi/#get-the-response-data (for how it populate headers field). I just followed it to init an empty array and populate the array with value.
SHA: 4706ca3 Reason: push, by chengweih001 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
SHA: 4706ca3 Reason: push, by chengweih001 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
SHA: 4706ca3 Reason: push, by chengweih001 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
SHA: 4706ca3 Reason: push, by chengweih001 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Complete the algorithms for
bluetooth.SimulateDescriptorResponse,bluetooth.DescriptorEventGenerated, andbluetooth.simulateDescriptor.Preview | Diff